Comfy-Org/ComfyUI · error · ValueError

sync.so rejects videos above 4K (4096x2160); got {width}x{he

Error message

sync.so rejects videos above 4K (4096x2160); got {width}x{height}. Downscale the video first.

What it means

Raised by the sync.so lipsync node when the input video's dimensions exceed the service's 4K cap: either the longer side is over 4096px or total pixels exceed 4096*2160. Dimensions come from video.get_dimensions(); if that raises, the check is skipped. It fires before audio validation and the generation request.

Source

Thrown at comfy_api_nodes/nodes_sync_so.py:150

            price_badge=IO.PriceBadge(
                expr="""{"type":"usd","usd":0.19019,"format":{"approximate":true,"suffix":"/second"}}""",
            ),
        )

    @classmethod
    async def execute(
        cls,
        video: Input.Video,
        audio: Input.Audio,
        seed: int,
        model: dict,
    ) -> IO.NodeOutput:
        try:
            width, height = video.get_dimensions()
        except Exception:
            width = height = None
        if width and height and (max(width, height) > 4096 or width * height > 4096 * 2160):
            raise ValueError(
                f"sync.so rejects videos above 4K (4096x2160); got {width}x{height}. Downscale the video first."
            )
        validate_audio_duration(audio, max_duration=600)

        if model["speaker_selection"] == "auto-detect":
            speaker_detection = SyncActiveSpeakerDetection(auto_detect=True)
        elif model["speaker_selection"] == "coordinates":
            speaker_detection = SyncActiveSpeakerDetection(
                frame_number=model["speaker_frame"],
                coordinates=[model["speaker_x"], model["speaker_y"]],
            )
        else:
            speaker_detection = None

        video_url = await upload_video_to_comfyapi(cls, video, max_duration=600)
        audio_url = await upload_audio_to_comfyapi(cls, audio)

        generation = await sync_op(

View on GitHub (pinned to 1c6d8d45b3)

Solutions

  1. Downscale the video to at most 4096 on the long side and 4096x2160 total pixels before the node (ffmpeg -vf scale)
  2. Use a video resize node upstream in the workflow
  3. Keep the aspect ratio when downscaling to avoid a second rejection on pixel count

Example fix

# before
sync_lipsync(video=video_6k, audio=a)

# after
# shell: ffmpeg -i in.mp4 -vf "scale='min(4096,iw)':-2" out.mp4
sync_lipsync(video=video_4k, audio=a)
Defensive patterns

Strategy: validation

Validate before calling

try:
    w, h = video.get_dimensions()
except Exception:
    w = h = None
if w and h and (max(w, h) > 4096 or w * h > 4096 * 2160):
    raise ValueError(f"Downscale {w}x{h} video to <=4096 long side / <=4096x2160 pixels")

Type guard

def is_syncso_safe_video(video) -> bool:
    try:
        w, h = video.get_dimensions()
    except Exception:
        return True
    return max(w, h) <= 4096 and w * h <= 4096 * 2160

Try / catch

try:
    await syncso_lipsync(video, audio)
except ValueError as e:
    if "above 4K" in str(e):
        video = downscale_video(video)  # then retry
        await syncso_lipsync(video, audio)
    else:
        raise

Prevention

When it happens

Trigger: Passing a video wider/taller than 4096 on the long side or with more than ~8.8MP total (e.g. 4096x2160+ or a huge square render) to the sync.so lipsync node.

Common situations: Using uncompressed 4K/6K camera originals or high-res renders directly; assuming the service downscales server-side (unlike the talking-image node, this video node has no auto_downscale).

Related errors


AI-assisted analysis of Comfy-Org/ComfyUI@1c6d8d45b3 (2026-08-14). Data as JSON: /api/errors/92c39ae15f90483d. Report an issue: GitHub.