{"record":{"id":"b77641bfe29a2746","repo":"Comfy-Org/ComfyUI","slug":"sync-so-rejects-images-above-4k-4096x2160-got","errorCode":null,"errorMessage":"sync.so rejects images above 4K (4096x2160); got {width}x{height}. Downscale the image first or enable auto_downscale.","messagePattern":"sync\\.so rejects images above 4K \\(4096x2160\\); got (.+?)x(.+?)\\. Downscale the image first or enable auto_downscale\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"comfy_api_nodes/nodes_sync_so.py","lineNumber":322,"sourceCode":"\n    @classmethod\n    async def execute(\n        cls,\n        image: Input.Image,\n        audio: Input.Audio,\n        prompt: str,\n        seed: int,\n        model: dict,\n    ) -> IO.NodeOutput:\n        if get_number_of_images(image) != 1:\n            raise ValueError(\"Exactly one image is required; got a batch. Pick one frame first.\")\n        validate_audio_duration(audio, max_duration=600)\n\n        height, width = get_image_dimensions(image)\n        speaker_x, speaker_y = model[\"speaker_x\"], model[\"speaker_y\"]\n        if max(width, height) > 4096 or width * height > 4096 * 2160:\n            if not model[\"auto_downscale\"]:\n                raise ValueError(\n                    f\"sync.so rejects images above 4K (4096x2160); got {width}x{height}. \"\n                    \"Downscale the image first or enable auto_downscale.\"\n                )\n            image = downscale_image_tensor(image, total_pixels=4096 * 2160)\n            image = downscale_image_tensor_by_max_side(image, max_side=4096)\n            new_height, new_width = get_image_dimensions(image)\n            # speaker coordinates are given in the original image's pixel space\n            speaker_x = min(new_width - 1, round(speaker_x * new_width / width))\n            speaker_y = min(new_height - 1, round(speaker_y * new_height / height))\n\n        if model[\"speaker_selection\"] == \"coordinates\":\n            speaker_detection = SyncActiveSpeakerDetection(\n                frame_number=0,  # images have a single frame; auto_detect is rejected by the API\n                coordinates=[speaker_x, speaker_y],\n            )\n        else:\n            speaker_detection = None\n","sourceCodeStart":304,"sourceCodeEnd":340,"githubUrl":"https://github.com/Comfy-Org/ComfyUI/blob/1c6d8d45b3693bfbb32385b410d813a7fd6be216/comfy_api_nodes/nodes_sync_so.py#L304-L340","documentation":"The sync.so talking-image node validates the input image against the provider's 4K cap before uploading: max(width, height) must be <= 4096 and width*height <= 4096*2160. When the image exceeds either bound and the model dict's auto_downscale flag is False, it raises ValueError immediately instead of letting the API reject the request. This is a client-side pre-flight check mirroring sync.so's server limit.","triggerScenarios":"Calling SyncTalkingImageNode.execute with an image larger than 4096 on the long side or more than 4096*2160 total pixels while model['auto_downscale'] is False (the node's toggle is off).","commonSituations":"Feeding high-resolution photos or upscaled renders (e.g. 6000x4000 portraits) into the talking-image node without resizing; workflows built for lower-res inputs later given print-resolution sources; users unaware of the auto_downscale option in the node's model config.","solutions":["Enable auto_downscale on the SyncTalkingImage model input (node UI toggle); the node then downscales to the cap and rescales the speaker_x/speaker_y coordinates automatically.","Downscale the image before the node with a standard image resize/downscale node so max side <= 4096 and total pixels <= 4096*2160.","If you need full-resolution output, run sync.so at 4K-or-less and upscale the returned video afterwards instead of the input image."],"exampleFix":"// before: 6000x4000 image, auto_downscale = False -> ValueError\n// after: enable auto_downscale in the model loader / node config\nmodel[\"auto_downscale\"] = True\nimage = talking_image(image=image, audio=audio, model=model)","handlingStrategy":"validation","validationCode":"h, w = get_image_dimensions(image)\nif (max(w, h) > 4096 or w * h > 4096 * 2160) and not model[\"auto_downscale\"]:\n    image = downscale_image_tensor_by_max_side(\n        downscale_image_tensor(image, total_pixels=4096 * 2160), max_side=4096\n    )","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Standardize talking-image inputs at <= 4096px long side in your workflow template.","Leave auto_downscale enabled unless you need exact pixel fidelity.","Remember speaker_x/speaker_y are in original pixel space; if you pre-downscale, rescale those coordinates too."],"tags":["validation","image","sync-so","api-nodes","pre-flight"],"backgroundTag":null,"analyzedSha":"1c6d8d45b3693bfbb32385b410d813a7fd6be216","analyzedAt":"2026-08-14T19:37:18.893Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}