{"record":{"id":"4ff61a69ecb02843","repo":"sgl-project/sglang","slug":"sana-wm-action-and-camera-to-world-camera-path-are","errorCode":null,"errorMessage":"SANA-WM action and camera_to_world/camera_path are mutually exclusive.","messagePattern":"SANA-WM action and camera_to_world/camera_path are mutually exclusive\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"python/sglang/multimodal_gen/runtime/pipelines_core/stages/model_specific_stages/sana_wm/base.py","lineNumber":1937,"sourceCode":"                    )\n        else:\n            camera_to_world = extra.get(\"camera_to_world\", None)\n            intrinsics = extra.get(\"intrinsics\", None)\n            if camera_to_world is None:\n                camera_to_world = self._first_mapping_value(\n                    diffusers_kwargs,\n                    \"camera_to_world\",\n                    \"camera_to_world_path\",\n                    \"camera_path\",\n                )\n            if intrinsics is None:\n                intrinsics = self._first_mapping_value(\n                    diffusers_kwargs,\n                    \"intrinsics\",\n                    \"intrinsics_path\",\n                )\n            if action is not None and camera_to_world is not None:\n                raise ValueError(\n                    \"SANA-WM action and camera_to_world/camera_path are \"\n                    \"mutually exclusive.\"\n                )\n\n            if action is not None:\n                source = (\n                    \"action\" if intrinsics is not None else \"action_default_intrinsics\"\n                )\n                translation_speed = self._request_float_value(\n                    extra,\n                    diffusers_kwargs,\n                    \"translation_speed\",\n                    \"action_translation_speed\",\n                    \"sana_wm_translation_speed\",\n                    default=_SANA_WM_DEFAULT_TRANSLATION_SPEED,\n                )\n                rotation_speed_deg = self._request_float_value(\n                    extra,","sourceCodeStart":1919,"sourceCodeEnd":1955,"githubUrl":"https://github.com/sgl-project/sglang/blob/0132848349585cfe6aae51c4941cbae872505f8a/python/sglang/multimodal_gen/runtime/pipelines_core/stages/model_specific_stages/sana_wm/base.py#L1919-L1955","documentation":"SANA-WM supports two camera-control modes: action conditioning (learned action vectors) or explicit camera_to_world/camera_path. Supplying both is ambiguous and rejected.","triggerScenarios":"Calling forward with both action is not None and camera_to_world (or camera_path via kwargs) set — e.g. an agent-style action array plus an explicit camera trajectory.","commonSituations":"Pipelines that default camera_to_world and then also forward user-supplied action; merging configs from examples that each use a different control mode.","solutions":["Remove camera_to_world/camera_path from diffusers_kwargs when using action conditioning.","Or drop the action tensor and keep only the explicit camera path.","Audit config merging so a default camera path doesn't leak into action-mode requests."],"exampleFix":"# before\nstage.forward(..., diffusers_kwargs={'action': act, 'camera_to_world': c2w})\n# after\nstage.forward(..., diffusers_kwargs={'action': act})","handlingStrategy":"type-guard","validationCode":"assert not (action is not None and (camera_to_world is not None or kwargs.get('camera_path') is not None))","typeGuard":"def control_mode_is_exclusive(action, camera_to_world, camera_path) -> bool:\n    return sum(x is not None for x in (action, camera_to_world, camera_path)) <= 1","tryCatchPattern":null,"preventionTips":["Model one control mode per request in your config schema.","Strip default camera keys from configs before injecting action."],"tags":["sglang","sana-wm","action-conditioning","mutually-exclusive-args","camera-control"],"backgroundTag":"conflicting-mutually-exclusive-arguments","analyzedSha":"0132848349585cfe6aae51c4941cbae872505f8a","analyzedAt":"2026-08-28T05:10:05.995Z","schemaVersion":2},"datasetVersion":"2026-08-28T06:17:29.519Z"}