Claude Code and Remotion long video: automatically checking audio-visual cut misalignment
Sampling frames at 20fps and comparing adjacent frames to find the seconds where the picture cuts, then checking them against the voice start seconds in plans/ch*.json, found 994 of 996 cuts within ±0.2 seconds with a median deviation of 0.07 seconds, at zero extra cost.
Claude Code × Remotionの長尺動画 声と画面の切り替わりのズレ検査の作り方 996か所を目で見る作業は一切不要。 追加費用も0円。 作り方のワークフローはこれ↓ ①完成した長尺を20fpsで読み込む ②隣のフレームとの差で、画面が切り替わった秒を拾う ③計画ファイル(plans/ch*.json)の、声の出だしに合わせた開始秒と照合 ④±0.2秒を超えた所だけを拾う(2か所) ⑤その2か所の前後4枚ずつスクショを撮る ⑥見出しカードの出現か、本当のズレかを判定 @masahirochaen さんの「最後にスクショを撮らせて、ズレがないかをチェックさせる」を回した結果、 996か所のうち994か所で、声と画面の切り替わりが±0.2秒以内。 ずれの中央値は0.07秒。 2か所は切り替わり済みで、遅れていたのは見出しカードの出現(+0.3〜0.5秒)でした。 動画と計画ファイルがあれば、同じ検査をそのまま回せます
This post quotes another post: x.com/3120155797/status/2106375997373468856