From 0bcd15d5e276ca6d3777a43a3d884c36b3245e3c Mon Sep 17 00:00:00 2001 From: Davids048 Date: Sun, 4 Oct 2026 04:45:02 +0000 Subject: [PATCH] [refactor]: delete FastVideoArgs, TrainingArgs, the flattening, and argparse ResolvedGeneratorConfig is the only runtime config. It answers only its typed fields, pipeline_config, mode, training_mode, and inference_mode; the transitional flat-name fallback is gone. Deleted: fastvideo/fastvideo_args.py (FastVideoArgs, TrainingArgs, their argparse, prepare/set/get_current_fastvideo_args), the flat-name fallback, generator_config_to_fastvideo_args and the other flattening helpers, PipelineConfig/model-config/PreprocessConfig/SamplingParam add_cli_args, configs/utils.py, and the tests of the deleted code. Materialization builds the model's PipelineConfig directly from the typed values through an explicit table of typed path to PipelineConfig mirror attribute (PIPELINE_CONFIG_MIRRORS); PipelineConfig.from_source replaces from_kwargs. flat_field metadata stays only on the fields behind the 24 from_pretrained keywords; a pipeline.experimental key that names a mirror attribute, and pipeline.preset / preset_version / components.vae_weights, are rejected during resolution. The training root keeps the DiT on the device through a resolution step instead of a from_pretrained override. The goldens snapshot the end-state objects (resolved config, PipelineConfig, decisions, request); the cli category is gone. Against the 3f6893a0 goldens, every field matches except disable_autocast, boundary_ratio, ltx2_vae_tiling (DESIGN section 9), and the fields that no longer exist. The schema parity inventory classifies the typed GeneratorConfig paths. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_012M91wnVFmPEvJ9h39r5BH7 --- .github/scripts/plan_merge_ci.py | 1 - docs/assets/cookbook-recipes.json | 2 +- .../inference_schema_parity_inventory.yaml | 261 +-- docs/design/server_contracts/dynamo.md | 5 +- .../installation/spark_pair.md | 2 +- .../installation/spark_performance.md | 7 +- docs/inference/architecture.md | 8 +- docs/inference/optimizations.md | 38 +- .../basic/basic_ltx2_3_distilled_i2v_typed.py | 60 +- .../basic_ltx2_distilled_fast_profile.py | 1 - .../basic_self_forcing_causal_wan2_2_t2v.py | 1 - .../optimizations/FastWan_QAD_TAEHV.py | 13 +- .../optimizations/fp8_wan2_1_1_3b.py | 12 +- .../optimizations/nvfp4_qat_wan2_1_1_3b.py | 8 +- examples/train/configs/example.yaml | 4 +- fastvideo/api/compat.py | 159 +- fastvideo/api/device_policy.py | 6 +- fastvideo/api/flat_name_fallback.py | 1401 --------------- fastvideo/api/inference_resolution.py | 260 +-- fastvideo/api/resolution.py | 43 +- fastvideo/api/sampling_param.py | 198 --- fastvideo/api/schema.py | 155 +- fastvideo/api/training_schema.py | 23 +- fastvideo/configs/AGENTS.md | 4 +- fastvideo/configs/configs.py | 136 -- fastvideo/configs/models/dits/base.py | 22 - fastvideo/configs/models/vaes/base.py | 103 -- fastvideo/configs/pipelines/base.py | 180 +- fastvideo/configs/utils.py | 57 - fastvideo/fastvideo_args.py | 1578 ----------------- .../lingbot_video/lingbot_video_pipeline.py | 4 +- fastvideo/pipelines/composed_pipeline_base.py | 4 - fastvideo/tests/api/config_snapshot.py | 144 +- ...ttention_backend_and_disable_autocast.json | 375 ---- .../cli/dit_config_flags.json | 375 ---- .../cli/offload_and_parallelism.json | 375 ---- .../cli/pipeline_config_flags.json | 375 ---- .../cli/vae_config_flags.json | 375 ---- .../attention_precision_and_flow_shift.json | 232 +-- .../config/boundary_ratio.json | 244 +-- .../experimental_keys.json} | 297 ++-- .../config/ltx2_refine_lora_disabled.json | 232 +-- .../config/ltx2_refine_lora_path.json | 232 +-- .../config/ltx2_vae_tile_sizes.json | 232 +-- ...r_port_refine_enabled_boundary_ratio.json} | 240 +-- .../config/pipeline_config_json_path.json | 233 +-- .../config/vae_tiling_typed.json | 232 +-- .../environment/attention_backend.json | 294 +-- ..._argument_wins_over_attention_backend.json | 288 +-- .../environment/inference_torch_compile.json | 293 +-- .../environment/vae_parallel.json | 288 +-- .../kwargs/disable_autocast.json | 232 +-- .../torch_compile_kwargs_typed_and_extra.json | 243 +-- .../kwargs/typed_offload_and_parallelism.json | 232 +-- ...tVideo__DreamX-World-5B-Cam-Diffusers.json | 286 ++- .../FastVideo__DreamX-World-5B-Diffusers.json | 297 +++- .../FastVideo__FastHunyuan-diffusers.json | 287 ++- ...FastVideo__FastVideo-FastH3-8-Step-V2.json | 283 ++- ...FastVideo-Minimax-FastH3-Preview-v0.2.json | 283 ++- ...tVideo__FastWan2.1-T2V-1.3B-Diffusers.json | 295 ++- ...eo__FastWan2.1-T2V-14B-480P-Diffusers.json | 295 ++- ...stVideo__FastWan2.2-TI2V-5B-Diffusers.json | 295 ++- ...FastWan2.2-TI2V-5B-FullAttn-Diffusers.json | 295 ++- .../FastVideo__GEN3C-Cosmos-7B-Diffusers.json | 285 ++- ..._HY-WorldPlay-Bidirectional-Diffusers.json | 287 ++- ...FastVideo__HunyuanGameCraft-Diffusers.json | 287 ++- ...astVideo__LTX-2.3-Distilled-Diffusers.json | 284 ++- .../registry/FastVideo__LTX2-Diffusers.json | 284 ++- .../FastVideo__LTX2-Distilled-Diffusers.json | 284 ++- .../registry/FastVideo__LTX2-base.json | 284 ++- .../registry/FastVideo__LTX2.3-Diffusers.json | 284 ++- ...FastVideo__LTX2.3-Distilled-Diffusers.json | 284 ++- .../registry/FastVideo__LTX2.3-base.json | 284 ++- ...o__LingBot-Video-Dense-1.3B-Diffusers.json | 285 ++- ...__LingBot-Video-MoE-30B-A3B-Diffusers.json | 285 ++- ...deo__LingBot-World-Base-Cam-Diffusers.json | 287 ++- ...astVideo__LongCat-Video-I2V-Diffusers.json | 285 ++- ...astVideo__LongCat-Video-T2V-Diffusers.json | 285 ++- ...FastVideo__LongCat-Video-VC-Diffusers.json | 285 ++- ...Video__MMAudio-large-44k-v2-Diffusers.json | 284 ++- ...Video__Matrix-Game-2.0-Base-Diffusers.json | 295 ++- ...rix-Game-2.0-Base-Distilled-Diffusers.json | 295 ++- ...tVideo__Matrix-Game-2.0-GTA-Diffusers.json | 295 ++- ...trix-Game-2.0-GTA-Distilled-Diffusers.json | 295 ++- ...__Matrix-Game-2.0-TempleRun-Diffusers.json | 295 ++- ...ame-2.0-TempleRun-Distilled-Diffusers.json | 295 ++- ...rix-Game-3.0-Base-Distilled-Diffusers.json | 286 ++- ...__SFWan2.2-I2V-A14B-Preview-Diffusers.json | 306 +++- ...eo__Wan2.1-VSA-T2V-14B-720P-Diffusers.json | 286 ++- ...ideo__stable-audio-open-1.0-Diffusers.json | 280 ++- ...eo__stable-audio-open-small-Diffusers.json | 280 ++- ...en__Wan2.1-Fun-1.3B-Control-Diffusers.json | 286 ++- ...eShao__Cosmos-Predict2.5-2B-Diffusers.json | 285 ++- .../registry/Lightricks__LTX-2.3.json | 284 ++- .../registry/Lightricks__LTX-2.json | 284 ++- .../registry/MiniMaxAI__MiniMax-H3.json | 283 ++- .../registry/Tongyi-MAI__Z-Image-Turbo.json | 285 ++- ...Wan-AI__Wan2.1-I2V-14B-480P-Diffusers.json | 286 ++- ...Wan-AI__Wan2.1-I2V-14B-720P-Diffusers.json | 286 ++- .../Wan-AI__Wan2.1-T2V-1.3B-Diffusers.json | 286 ++- .../Wan-AI__Wan2.1-T2V-14B-Diffusers.json | 286 ++- .../Wan-AI__Wan2.2-I2V-A14B-Diffusers.json | 287 ++- .../Wan-AI__Wan2.2-T2V-A14B-Diffusers.json | 298 +++- .../Wan-AI__Wan2.2-TI2V-5B-Diffusers.json | 286 ++- .../black-forest-labs__FLUX.1-dev.json | 286 ++- .../black-forest-labs__FLUX.2-dev.json | 284 ++- .../black-forest-labs__FLUX.2-klein-4B.json | 283 ++- .../black-forest-labs__FLUX.2-klein-9B.json | 283 ++- .../decart-ai__Lucy-Edit-1.1-Dev.json | 286 ++- .../registry/decart-ai__Lucy-Edit-Dev.json | 286 ++- ...1.5-Diffusers-480p_i2v_step_distilled.json | 287 ++- ...__HunyuanVideo-1.5-Diffusers-480p_t2v.json | 287 ++- ...ideo-1.5-Diffusers-720p_i2v_distilled.json | 287 ++- ...__HunyuanVideo-1.5-Diffusers-720p_t2v.json | 287 ++- .../hunyuanvideo-community__HunyuanVideo.json | 287 ++- ...__Kandinsky-5.0-I2V-Lite-5s-Diffusers.json | 287 ++- ...ky-5.0-I2V-Pro-distilled-5s-Diffusers.json | 287 ++- ...andinsky-5.0-I2V-Pro-sft-5s-Diffusers.json | 287 ++- ...2V-Lite-distilled16steps-5s-Diffusers.json | 287 ++- ...ndinsky-5.0-T2V-Lite-sft-5s-Diffusers.json | 287 ++- ...ky-5.0-T2V-Pro-distilled-5s-Diffusers.json | 287 ++- ...andinsky-5.0-T2V-Pro-sft-5s-Diffusers.json | 287 ++- ...ashid__TurboWan2.1-T2V-1.3B-Diffusers.json | 285 ++- ...rashid__TurboWan2.1-T2V-14B-Diffusers.json | 285 ++- ...ashid__TurboWan2.2-I2V-A14B-Diffusers.json | 286 ++- .../mignonjia__mg_bidirectional_zelda.json | 295 ++- .../registry/mignonjia__mg_causal_zelda.json | 295 ++- ...nonjia__mg_longtuning_distilled_zelda.json | 295 ++- .../mignonjia__mg_sf_distilled_zelda.json | 295 ++- ...onjia__mg_sf_distilled_zelda_1k_steps.json | 295 ++- ...vidia__Cosmos-Predict2-2B-Video2World.json | 285 ++- .../nvidia__Cosmos-Predict2.5-14B.json | 285 ++- ...rand0nmr__SFWan2.2-T2V-A14B-Diffusers.json | 306 +++- ...ant__lingbot-world-v2-14b-causal-fast.json | 287 ++- ...bilityai__stable-diffusion-3.5-medium.json | 288 ++- ..._HunyuanVideo-1.5-Diffusers-1080p-2SR.json | 287 ++- ...u03__HunyuanVideo-1.5-Diffusers-1080p.json | 287 ++- ...zhou03__Wan2.1-Fun-1.3B-InP-Diffusers.json | 286 ++- ...wlsaidhi__SFWan2.1-T2V-1.3B-Diffusers.json | 297 +++- .../registry/zai-org__GLM-Image.json | 285 ++- ...e__serve_configs__streaming_demo.yaml.json | 256 +-- ...rence__ltx2_3__i2v_5s2_1024x1536.yaml.json | 243 +-- ...erence__ltx2_3__i2v_5s2_1280x832.yaml.json | 243 +-- ...ference__ltx2_3__i2v_5s2_512x768.yaml.json | 243 +-- ...erence__ltx2_3__i2v_5s2_768x1280.yaml.json | 243 +-- ...rence__ltx2_3__i2v_8s3_1024x1536.yaml.json | 243 +-- ...erence__ltx2_3__i2v_8s3_1280x832.yaml.json | 243 +-- ...ference__ltx2_3__i2v_8s3_512x768.yaml.json | 243 +-- ...erence__ltx2_3__i2v_8s3_768x1280.yaml.json | 243 +-- ...rence__ltx2_3__t2v_5s2_1024x1536.yaml.json | 243 +-- ...erence__ltx2_3__t2v_5s2_1280x832.yaml.json | 243 +-- ...ference__ltx2_3__t2v_5s2_512x768.yaml.json | 243 +-- ...erence__ltx2_3__t2v_5s2_768x1280.yaml.json | 243 +-- ...rence__ltx2_3__t2v_8s3_1024x1536.yaml.json | 243 +-- ...erence__ltx2_3__t2v_8s3_1280x832.yaml.json | 243 +-- ...ference__ltx2_3__t2v_8s3_512x768.yaml.json | 243 +-- ...erence__ltx2_3__t2v_8s3_768x1280.yaml.json | 243 +-- ...examples__serving__openai_fasth3.yaml.json | 230 ++- ...es__serving__openai_fasth3_8step.yaml.json | 230 ++- ...les__serving__openai_fasth3_lora.yaml.json | 230 ++- ...__serving__openai_fastwan21_1_3b.yaml.json | 234 ++- ...s__serving__openai_wan21_i2v_14b.yaml.json | 230 ++- ...__serving__openai_wan22_t2v_a14b.yaml.json | 235 ++- ...s__serving__openai_wan22_ti2v_5b.yaml.json | 230 ++- ...xamples__serving__streaming_demo.yaml.json | 256 +-- ...inference__inference_fasthunyuan.yaml.json | 231 ++- ...inference__inference_flux2_klein.yaml.json | 230 ++- ...ts__inference__inference_hunyuan.yaml.json | 231 ++- ...ts__inference__inference_longcat.yaml.json | 230 ++- ...rence__inference_longcat_distill.yaml.json | 230 ++- ...inference__inference_longcat_i2v.yaml.json | 230 ++- ...ference_longcat_refine_fromvideo.yaml.json | 238 ++- ..._inference__inference_longcat_vc.yaml.json | 230 ++- ...cripts__inference__inference_wan.yaml.json | 230 ++- ...erence__inference_wan_1.3B_VMoba.yaml.json | 274 +-- ...ts__inference__inference_wan_VSA.yaml.json | 230 ++- ...__inference_wan_VSA_DMD_14B_480P.yaml.json | 234 ++- ...__inference_wan_VSA_DMD_14B_720P.yaml.json | 234 ++- ...ence__inference_wan_VSA_DMD_1_3B.yaml.json | 234 ++- ...e__inference_wan_VSA_DMD_5B_720P.yaml.json | 234 ++- ...ts__inference__inference_wan_i2v.yaml.json | 230 ++- .../tests/api/test_compat_translation.py | 16 +- .../test_config_snapshot_matches_golden.py | 38 +- .../tests/api/test_fastvideo_args_freeze.py | 86 - .../api/test_generator_config_flat_names.py | 30 - .../api/test_inference_resolution_steps.py | 3 +- .../tests/api/test_resolved_runtime_config.py | 104 +- .../tests/api/test_schema_parity_inventory.py | 32 +- fastvideo/tests/api/test_typed_quant_flow.py | 11 +- .../tests/entrypoints/test_video_generator.py | 4 +- .../tests/train/callbacks/test_validation.py | 7 +- .../test_moduleloader_attention_backend.py | 2 +- fastvideo/train/utils/config.py | 14 +- 193 files changed, 25025 insertions(+), 20675 deletions(-) delete mode 100644 fastvideo/api/flat_name_fallback.py delete mode 100644 fastvideo/configs/utils.py delete mode 100644 fastvideo/fastvideo_args.py delete mode 100644 fastvideo/tests/api/config_snapshot_goldens/cli/attention_backend_and_disable_autocast.json delete mode 100644 fastvideo/tests/api/config_snapshot_goldens/cli/dit_config_flags.json delete mode 100644 fastvideo/tests/api/config_snapshot_goldens/cli/offload_and_parallelism.json delete mode 100644 fastvideo/tests/api/config_snapshot_goldens/cli/pipeline_config_flags.json delete mode 100644 fastvideo/tests/api/config_snapshot_goldens/cli/vae_config_flags.json rename fastvideo/tests/api/config_snapshot_goldens/{cli/model_path_only.json => config/experimental_keys.json} (56%) rename fastvideo/tests/api/config_snapshot_goldens/config/{keys_without_typed_fields.json => master_port_refine_enabled_boundary_ratio.json} (71%) delete mode 100644 fastvideo/tests/api/test_fastvideo_args_freeze.py delete mode 100644 fastvideo/tests/api/test_generator_config_flat_names.py diff --git a/.github/scripts/plan_merge_ci.py b/.github/scripts/plan_merge_ci.py index db79723ce..fc2e799e2 100644 --- a/.github/scripts/plan_merge_ci.py +++ b/.github/scripts/plan_merge_ci.py @@ -489,7 +489,6 @@ def classify_paths(paths: list[str]) -> MergePlan: _select_output_coverage(plan, path) continue if path in { - "fastvideo/fastvideo_args.py", "fastvideo/forward_context.py", "fastvideo/image_processor.py", "fastvideo/registry.py", diff --git a/docs/assets/cookbook-recipes.json b/docs/assets/cookbook-recipes.json index 8875361dc..7d8646f39 100644 --- a/docs/assets/cookbook-recipes.json +++ b/docs/assets/cookbook-recipes.json @@ -544,7 +544,7 @@ "limitations": [ "Install from the DGX Spark guide, not the generic CUDA extra. GB10 has no FA4 / sm_100a VSA kernel; keep FASTVIDEO_FA4=0 and FASTVIDEO_VSA_SM100A=0.", "Legal num_frames values are 17n+5, capped at 345 (15 s). Native 16:9 sizes include 832x480 and 1344x768.", - "Lazy module load reloads Qwen3-VL and the DiT between phases of each request. Do not pass --no-lazy-module-load on this box.", + "Lazy module load reloads Qwen3-VL and the DiT between phases of each request. Do not set engine.offload.lazy_module_load to false on this box.", "A 345-frame request on one Spark can OOM. Prefer 124 or 243 frames, TAEH3 decode, or two Sparks over QSFP." ] }, diff --git a/docs/design/inference_schema_parity_inventory.yaml b/docs/design/inference_schema_parity_inventory.yaml index 2d3042b68..2427f17cf 100644 --- a/docs/design/inference_schema_parity_inventory.yaml +++ b/docs/design/inference_schema_parity_inventory.yaml @@ -2,133 +2,151 @@ status_definitions: kept: "Public field remains on a public adapter surface with the same meaning." moved: "Public field remains supported but normalizes into a different nested path." preset_owned: "Public field remains supported only through a model/preset-specific surface." - compatibility_only: "Legacy public field remains adapter-only during migration and is not part of the canonical typed schema." + from_pretrained_keyword: "Typed config field that an argument of VideoGenerator.from_pretrained also sets; the entry value names that argument." + compatibility_only: "Public field that an adapter or an open mapping accepts outside the typed fields of the canonical schema." private_only: "Field should only be handled by private adapters and is not a public FastVideo compatibility promise." - internal_only: "Field is runtime/config plumbing and should not be part of the new public typed inference API." + internal_only: "Field is runtime/config plumbing that model code, config resolution, or the runtime fills; it is not a public input." + unsupported: "Typed config field that no runtime code reads; resolution rejects a value." surfaces: - fastvideo_args: + generator_config: + from_pretrained_keyword: + model_path: "model_path (positional argument)" + revision: revision + trust_remote_code: trust_remote_code + engine.num_gpus: num_gpus + engine.execution_backend: distributed_executor_backend + engine.parallelism.tp_size: tp_size + engine.parallelism.sp_size: sp_size + engine.parallelism.hsdp_replicate_dim: hsdp_replicate_dim + engine.parallelism.hsdp_shard_dim: hsdp_shard_dim + engine.parallelism.dist_timeout: dist_timeout + engine.offload.dit: dit_cpu_offload + engine.offload.dit_layerwise: dit_layerwise_offload + engine.offload.text_encoder: text_encoder_cpu_offload + engine.offload.image_encoder: image_encoder_cpu_offload + engine.offload.vae: vae_cpu_offload + engine.offload.pin_cpu_memory: pin_cpu_memory + engine.compile.enabled: enable_torch_compile + engine.compile.backend: "torch_compile_kwargs['backend']" + engine.compile.fullgraph: "torch_compile_kwargs['fullgraph']" + engine.compile.mode: "torch_compile_kwargs['mode']" + engine.compile.dynamic: "torch_compile_kwargs['dynamic']" + engine.compile.extras: "torch_compile_kwargs keys other than backend, fullgraph, mode, and dynamic" + engine.enable_stage_verification: enable_stage_verification + engine.use_fsdp_inference: use_fsdp_inference + engine.disable_autocast: disable_autocast + pipeline.components.lora_path: lora_path + pipeline.components.lora_strength: lora_strength + pipeline.output_type: output_type + kept: + - mode + - engine.parallelism.master_port + - engine.offload.lazy_module_load + - engine.compile.text_encoder_enabled + - engine.compile.vae_enabled + - engine.compile.audio_vae_enabled + - engine.compile.regional + - engine.compile.dit_kwargs + - engine.compile.text_encoder_kwargs + - engine.compile.vae_kwargs + - engine.compile.audio_vae_kwargs + - engine.attention.backend + - engine.attention.vsa_sparsity + - engine.attention.vsa_tile_size + - engine.attention.moba_config_path + - engine.precision.dit + - engine.precision.vae + - engine.precision.vae_decode + - engine.precision.image_encoder + - engine.precision.text_encoders + - engine.quantization.text_encoder_quant + - engine.quantization.transformer_quant + - pipeline.workload_type + - pipeline.components.config_root + - pipeline.components.pipeline_config_path + - pipeline.components.text_encoder_weights + - pipeline.components.transformer_weights + - pipeline.components.transformer_2_weights + - pipeline.components.upsampler_weights + - pipeline.components.lora_nickname + - pipeline.components.lora_target_modules + - pipeline.components.override_pipeline_cls_name + - pipeline.components.override_transformer_cls_name + - pipeline.vae_tiling + - pipeline.vae_sp + - pipeline.flow_shift + - pipeline.embedded_cfg_scale + - pipeline.dmd_denoising_steps + - pipeline.boundary_ratio + - pipeline.dit + - pipeline.vae + unsupported: + - pipeline.preset + - pipeline.preset_version + - pipeline.components.vae_weights moved: - model_path: generator.model_path - workload_type: generator.pipeline.workload_type - distributed_executor_backend: generator.engine.execution_backend - trust_remote_code: generator.trust_remote_code - revision: generator.revision - num_gpus: generator.engine.num_gpus - tp_size: generator.engine.parallelism.tp_size - sp_size: generator.engine.parallelism.sp_size - hsdp_replicate_dim: generator.engine.parallelism.hsdp_replicate_dim - hsdp_shard_dim: generator.engine.parallelism.hsdp_shard_dim - dist_timeout: generator.engine.parallelism.dist_timeout - lora_path: generator.pipeline.components.lora_path - lora_nickname: generator.pipeline.components.lora_nickname - lora_strength: generator.pipeline.components.lora_strength - dit_cpu_offload: generator.engine.offload.dit - use_fsdp_inference: generator.engine.use_fsdp_inference - dit_layerwise_offload: generator.engine.offload.dit_layerwise - text_encoder_cpu_offload: generator.engine.offload.text_encoder - image_encoder_cpu_offload: generator.engine.offload.image_encoder - vae_cpu_offload: generator.engine.offload.vae - pin_cpu_memory: generator.engine.offload.pin_cpu_memory - lazy_module_load: generator.engine.offload.lazy_module_load - enable_torch_compile: generator.engine.compile.enabled - enable_torch_compile_text_encoder: generator.engine.compile.text_encoder_enabled - enable_torch_compile_vae: generator.engine.compile.vae_enabled - enable_torch_compile_audio_vae: generator.engine.compile.audio_vae_enabled - torch_compile_kwargs: generator.engine.compile.backend,fullgraph,mode,dynamic,extras - torch_compile_kwargs_dit: generator.engine.compile.dit_kwargs - torch_compile_kwargs_text_encoder: generator.engine.compile.text_encoder_kwargs - torch_compile_kwargs_vae: generator.engine.compile.vae_kwargs - torch_compile_kwargs_audio_vae: generator.engine.compile.audio_vae_kwargs - transformer_quant: generator.engine.quantization.transformer_quant - disable_autocast: generator.engine.disable_autocast - enable_stage_verification: generator.engine.enable_stage_verification - prompt_txt: request.inputs.prompt_path - override_text_encoder_safetensors: generator.pipeline.components.text_encoder_weights - override_text_encoder_quant: generator.engine.quantization.text_encoder_quant - transformer_quant: generator.engine.quantization.transformer_quant - override_transformer_cls_name: generator.pipeline.components.override_transformer_cls_name - init_weights_from_safetensors: generator.pipeline.components.transformer_weights - init_weights_from_safetensors_2: generator.pipeline.components.transformer_2_weights - override_pipeline_cls_name: generator.pipeline.components.override_pipeline_cls_name - boundary_ratio: request.sampling.boundary_ratio - ltx2_vae_tiling: generator.pipeline.vae_tiling - refine_enabled: generator.pipeline.preset_overrides.refine.enabled - refine_upsampler_path: generator.pipeline.components.upsampler_weights - refine_lora_path: generator.pipeline.ltx2.refine.lora_path - refine_num_inference_steps: request.stage_overrides.refine.num_inference_steps - refine_guidance_scale: request.stage_overrides.refine.guidance_scale - refine_add_noise: generator.pipeline.preset_overrides.refine.add_noise - ltx2_refine_enabled: generator.pipeline.preset_overrides.refine.enabled - ltx2_refine_upsampler_path: generator.pipeline.components.upsampler_weights - ltx2_refine_lora_path: generator.pipeline.ltx2.refine.lora_path - ltx2_refine_num_inference_steps: request.stage_overrides.refine.num_inference_steps - ltx2_refine_guidance_scale: request.stage_overrides.refine.guidance_scale - ltx2_refine_add_noise: generator.pipeline.preset_overrides.refine.add_noise - lora_target_modules: generator.pipeline.components.lora_target_modules - attention_backend: generator.engine.attention.backend - VSA_sparsity: generator.engine.attention.vsa_sparsity - VSA_tile_size: generator.engine.attention.vsa_tile_size - moba_config_path: generator.engine.attention.moba_config_path - inference_torch_compile: generator.engine.compile.regional - vae_parallel_decode: generator.pipeline.minimax_h3.vae_parallel_decode - vae_parallel_encode: generator.pipeline.minimax_h3.vae_parallel_encode - vae_parallel_decode_strategy: generator.pipeline.minimax_h3.vae_parallel_decode_strategy - h3_sequential_load: generator.pipeline.minimax_h3.sequential_load - video_decode_backend: generator.pipeline.minimax_h3.video_decode_backend - taeh3_checkpoint: generator.pipeline.minimax_h3.taeh3_checkpoint - taeh3_chunk_size: generator.pipeline.minimax_h3.taeh3_chunk_size - refine_transformer_path: generator.pipeline.ltx2.refine.transformer_path - refine_noise_path: generator.pipeline.ltx2.refine.noise_path - refine_audio_noise_path: generator.pipeline.ltx2.refine.audio_noise_path - ltx2_refine_transformer_path: generator.pipeline.ltx2.refine.transformer_path - ltx2_refine_noise_path: generator.pipeline.ltx2.refine.noise_path - ltx2_refine_audio_noise_path: generator.pipeline.ltx2.refine.audio_noise_path - ltx2_legacy_native_noise_order: generator.pipeline.ltx2.legacy_native_noise_order - ltx2_use_distilled_sigmas: generator.pipeline.ltx2.use_distilled_sigmas - ltx2_vae_spatial_tile_size_in_pixels: generator.pipeline.ltx2.vae_spatial_tile_size_in_pixels - ltx2_vae_spatial_tile_overlap_in_pixels: generator.pipeline.ltx2.vae_spatial_tile_overlap_in_pixels - ltx2_vae_temporal_tile_size_in_frames: generator.pipeline.ltx2.vae_temporal_tile_size_in_frames - ltx2_vae_temporal_tile_overlap_in_frames: generator.pipeline.ltx2.vae_temporal_tile_overlap_in_frames - ltx2_initial_latent_path: generator.pipeline.ltx2.initial_latent_path - ltx2_audio_latent_path: generator.pipeline.ltx2.audio_latent_path + pipeline.preset_overrides: + target: generator.pipeline.ltx2.refine + note: "Only the refine mapping applies: resolution copies pipeline.preset_overrides.refine into the pipeline.ltx2.refine fields of the same names. Other keys have no effect." + preset_owned: + - pipeline.ltx2.vae_spatial_tile_size_in_pixels + - pipeline.ltx2.vae_spatial_tile_overlap_in_pixels + - pipeline.ltx2.vae_temporal_tile_size_in_frames + - pipeline.ltx2.vae_temporal_tile_overlap_in_frames + - pipeline.ltx2.initial_latent_path + - pipeline.ltx2.audio_latent_path + - pipeline.ltx2.legacy_native_noise_order + - pipeline.ltx2.use_distilled_sigmas + - pipeline.ltx2.refine.enabled + - pipeline.ltx2.refine.num_inference_steps + - pipeline.ltx2.refine.guidance_scale + - pipeline.ltx2.refine.add_noise + - pipeline.ltx2.refine.image_crf + - pipeline.ltx2.refine.video_position_offset_sec + - pipeline.ltx2.refine.transformer_path + - pipeline.ltx2.refine.lora_path + - pipeline.ltx2.refine.noise_path + - pipeline.ltx2.refine.audio_noise_path + - pipeline.minimax_h3.sequential_load + - pipeline.minimax_h3.video_decode_backend + - pipeline.minimax_h3.taeh3_checkpoint + - pipeline.minimax_h3.taeh3_chunk_size + - pipeline.minimax_h3.vae_parallel_decode + - pipeline.minimax_h3.vae_parallel_encode + - pipeline.minimax_h3.vae_parallel_decode_strategy + - pipeline.longcat.enable_bsa + - pipeline.longcat.bsa_sparsity + - pipeline.longcat.bsa_cdf_threshold + - pipeline.longcat.bsa_chunk_q + - pipeline.longcat.bsa_chunk_k compatibility_only: - mode: "Legacy multi-mode FastVideoArgs switch; typed inference config should not expose execution mode." - inference_mode: "Legacy boolean mirror of mode; kept only through adapters while FastVideoArgs remains." - output_type: "Legacy output formatting surface pending GenerationResult cleanup." - master_port: "Executor/bootstrap compatibility field; not part of the canonical inference schema." - private_only: - ray_placement_group: "Ray deployment-only field." - ray_runtime_env: "Ray deployment-only field." + pipeline.experimental: "Open mapping for settings without a typed path: the pipeline_config source (a JSON path, a mapping, or a PipelineConfig), keys that runtime code reads by name (for example ray_runtime_env), and PipelineConfig attribute overrides for model-only fields (for example flow_shift_sr). Resolution rejects a key whose PipelineConfig attribute has a typed path." internal_only: - pipeline_config: "Legacy internal carrier object." - preprocess_config: "Legacy preprocess carrier object." - moba_config: "Derived runtime config loaded from moba_config_path." - model_paths: "Runtime bookkeeping." - model_loaded: "Runtime bookkeeping." + engine.attention.moba_config: "V-MoBA attention settings that resolution loads from engine.attention.moba_config_path." pipeline_config_base: moved: + model_path: generator.model_path pipeline_config_path: generator.pipeline.components.pipeline_config_path embedded_cfg_scale: generator.pipeline.embedded_cfg_scale flow_shift: generator.pipeline.flow_shift + disable_autocast: generator.engine.disable_autocast + vae_tiling: generator.pipeline.vae_tiling vae_sp: generator.pipeline.vae_sp dmd_denoising_steps: generator.pipeline.dmd_denoising_steps + boundary_ratio: generator.pipeline.boundary_ratio dit_precision: generator.engine.precision.dit vae_precision: generator.engine.precision.vae vae_decode_precision: generator.engine.precision.vae_decode image_encoder_precision: generator.engine.precision.image_encoder text_encoder_precisions: generator.engine.precision.text_encoders preset_owned: - flow_shift_sr: generator.pipeline.preset_overrides.flow_shift_sr - is_causal: generator.pipeline.preset_overrides.is_causal - vae_tiling: generator.pipeline.preset_overrides.vae_tiling - ti2v_task: generator.pipeline.preset_overrides.ti2v_task - lucy_edit_task: generator.pipeline.preset_overrides.lucy_edit_task - boundary_ratio: generator.pipeline.preset_overrides.boundary_ratio + flow_shift_sr: generator.pipeline.experimental.flow_shift_sr + is_causal: generator.pipeline.experimental.is_causal + ti2v_task: generator.pipeline.experimental.ti2v_task + lucy_edit_task: generator.pipeline.experimental.lucy_edit_task compatibility_only: - model_path: "Redundant with generator.model_path." - disable_autocast: "Duplicated by generator.engine.disable_autocast during migration." upsampler_precision: "Precision override pending dedicated typed component precision design." image_encoder_precisions: "Precision overrides pending dedicated typed component precision design." internal_only: @@ -143,6 +161,22 @@ surfaces: scheduler_step_in_fp32: "Runtime scheduler precision toggle; not part of the public typed inference API." pipeline_config_extensions: + moved: + enable_bsa: + sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] + target: generator.pipeline.longcat.enable_bsa + bsa_sparsity: + sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] + target: generator.pipeline.longcat.bsa_sparsity + bsa_cdf_threshold: + sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] + target: generator.pipeline.longcat.bsa_cdf_threshold + bsa_chunk_q: + sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] + target: generator.pipeline.longcat.bsa_chunk_q + bsa_chunk_k: + sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] + target: generator.pipeline.longcat.bsa_chunk_k preset_owned: flux2_text_encoder_type: sources: @@ -323,23 +357,8 @@ surfaces: - fastvideo.configs.pipelines.wan.WanI2V720PConfig - fastvideo.configs.pipelines.wan.WanT2V480PConfig - fastvideo.configs.pipelines.wan.WanT2V720PConfig - bsa_cdf_threshold: - sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] - target: generator.pipeline.longcat.bsa_cdf_threshold - bsa_chunk_k: - sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] - target: generator.pipeline.longcat.bsa_chunk_k - bsa_chunk_q: - sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] - target: generator.pipeline.longcat.bsa_chunk_q bsa_params: sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] - bsa_sparsity: - sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] - target: generator.pipeline.longcat.bsa_sparsity - enable_bsa: - sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] - target: generator.pipeline.longcat.enable_bsa enable_kv_cache: sources: [fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig, fastvideo.configs.pipelines.longcat.LongCatT2V704PConfig] enhance_hf: diff --git a/docs/design/server_contracts/dynamo.md b/docs/design/server_contracts/dynamo.md index df9fe9c94..c163cab2e 100644 --- a/docs/design/server_contracts/dynamo.md +++ b/docs/design/server_contracts/dynamo.md @@ -311,8 +311,9 @@ re-chase FastVideo drift: special-casing torch tensors. 3. `VideoGenerator.from_pretrained` accepts a typed `GeneratorConfig`. Its only flat keywords are the convenience keywords in - `fastvideo.api.compat.FROM_PRETRAINED_KWARGS`; any other flat keyword - raises `TypeError` that names the typed config path to use instead. + `fastvideo.api.compat.FROM_PRETRAINED_KWARGS`; any other keyword + raises `TypeError` that points to `VideoGenerator.from_config(...)`, + which takes every setting at its typed config path. 4. `generate_async` (PR 7.10+) emits events in order `Progress* → Partial* → Final`; the final event always has exactly one occurrence per request. diff --git a/docs/getting_started/installation/spark_pair.md b/docs/getting_started/installation/spark_pair.md index fe8aee1aa..1d63aa1f1 100644 --- a/docs/getting_started/installation/spark_pair.md +++ b/docs/getting_started/installation/spark_pair.md @@ -197,7 +197,7 @@ sm_100a VSA kernel is not on this chip, so denoise is slower than a GB200 | NCCL hangs or uses Wi-Fi | `source spark_pair_env.sh`. Confirm `NCCL_SOCKET_IFNAME` is the QSFP NIC. | | Gloo `connectFullMesh` / `remote=[127.0.0.1]` | Two 1-GPU nodes must not use loopback as the Gloo store. Source `spark_pair_env.sh` so `GLOO_SOCKET_IFNAME` is the QSFP NIC on **each** box. FastVideo no longer copies that NIC name from the driver onto workers. | | Second `generate()` crashes `NoneType.parameters` | Sequential load used to drop the text encoder without reloading it. This branch reloads Qwen for later requests so `--warmup --repeats N` works. | -| OOM / `earlyoom` prefers Python | Lazy module load must stay on (do not pass `--no-lazy-module-load`). Peak GPU during 345-frame denoise is ~90 GiB/node. | +| OOM / `earlyoom` prefers Python | Lazy module load must stay on (do not pass `--no-lazy-module-load` to `basic_fasth3.py` or set `engine.offload.lazy_module_load: false`). Peak GPU during 345-frame denoise is ~90 GiB/node. | | `num_gpus=2` on one Spark | Each Spark has one GPU. Use Ray across two nodes, or `num_gpus=1` on one box. | ## What we are not claiming diff --git a/docs/getting_started/installation/spark_performance.md b/docs/getting_started/installation/spark_performance.md index 41f506e86..767c9f38c 100644 --- a/docs/getting_started/installation/spark_performance.md +++ b/docs/getting_started/installation/spark_performance.md @@ -168,8 +168,9 @@ is power-cycled. To avoid it: encoder is still resident, the process is a typical `earlyoom` kill (Python is preferred). On unified memory, `lazy_module_load` auto-enables and owns that split (encoder, then DiT, then VAE; DiT can drop before decode). Sequential - load is the H3-only fallback when lazy is off; do not pass - `--no-lazy-module-load` here. Geometry scalars come from checkpoint + load is the H3-only fallback when lazy is off; do not set + `engine.offload.lazy_module_load` to false here (`--no-lazy-module-load` in + `basic_fasth3.py` and `basic_minimax_h3_t2v.py`). Geometry scalars come from checkpoint `config.json`, not live weights. See [Offloading](../../inference/offloading.md). - **FastH3 TAEH3** (`--video-decode-backend taeh3`) is an opt-in preview decoder. T2VA never materializes the 9.7 GiB video VAE (DiT still loads after Qwen via @@ -203,7 +204,7 @@ A few things that surprise people on this box (beyond the memory notes above): build recent enough to include its `transformers`-compatibility handling before running it. - **MiniMax H3 worker init can look healthy and still die on the first generate** - if deferred loading is off (`--no-lazy-module-load` and sequential also off) + if deferred loading is off (`engine.offload.lazy_module_load: false` and sequential also off) and encoder, VAE, and DiT load together. On GB10 the log should show `lazy_module_load owns deferral` (or, if lazy is off, sequential `Released MiniMax-H3 text encoder after conditioning` before diff --git a/docs/inference/architecture.md b/docs/inference/architecture.md index 6d0d80068..e22913cda 100644 --- a/docs/inference/architecture.md +++ b/docs/inference/architecture.md @@ -131,9 +131,11 @@ Concrete hierarchy: `DiTConfig` → `DiTArchConfig`, `VAEConfig` → - `PipelineConfig.from_pretrained(model_path)` — resolves config class via `get_pipeline_config_cls_from_name()`, instantiates with defaults. -- `PipelineConfig.from_kwargs(kwargs)` — resolves class, optionally loads - JSON via `load_from_json()`, then applies keyword overrides via - `update_config_from_dict()`. +- `PipelineConfig.from_source(model_path, source)` — resolves the registry + class of `model_path`, then updates it from `source`: a JSON path loaded + via `load_from_json()`, a mapping of field values applied via + `update_pipeline_config()`, or a `PipelineConfig` that replaces the + registry instance. - `dump_to_json()` / `load_from_json()` — JSON persistence. Callable fields and `arch_config` are excluded from dumps. diff --git a/docs/inference/optimizations.md b/docs/inference/optimizations.md index 1b9a32a9a..0ae7309e0 100644 --- a/docs/inference/optimizations.md +++ b/docs/inference/optimizations.md @@ -205,19 +205,13 @@ import os os.environ["FASTVIDEO_ATTENTION_BACKEND"] = "ATTN_QAT_INFER" from fastvideo import VideoGenerator -from fastvideo.layers.quantization import get_quantization_config gen = VideoGenerator.from_config({ "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", "engine": { "num_gpus": 1, "use_fsdp_inference": False, # FSDP shards invalidate the FP4 tensor pointers - }, - "pipeline": { - "experimental": { - # Wan-2.1 uses the nvfp4_qat config (NVFP4 is LTX2-specific). Pass an - # instance — the bare string is not resolved under pipeline.experimental. - "transformer_quant": get_quantization_config("nvfp4_qat")(), - }, + # Wan-2.1 uses the nvfp4_qat config (NVFP4 is LTX2-specific). + "quantization": {"transformer_quant": "nvfp4_qat"}, }, }) gen.generate(request={"prompt": "A raccoon in sunflowers", "output": {"save_video": True}}) @@ -307,6 +301,20 @@ automatically. ### Usage +```python +from fastvideo import VideoGenerator + +gen = VideoGenerator.from_config({ + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "engine": {"quantization": {"transformer_quant": "FP8"}}, # per-tensor (default) +}) +gen.generate(request={"prompt": "A raccoon in sunflowers", "output": {"save_video": True}}) +``` + +`engine.quantization.transformer_quant` takes a quantization registry name and builds that config with its default +arguments. To pass constructor arguments, such as per-channel granularity, set the config instance on the DiT config +through `pipeline.dit` instead: + ```python from fastvideo import VideoGenerator from fastvideo.layers.quantization import get_quantization_config @@ -314,14 +322,9 @@ from fastvideo.layers.quantization import get_quantization_config gen = VideoGenerator.from_config({ "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", "pipeline": { - "experimental": { - # Pass an instance — the bare string is not resolved under pipeline.experimental. - "transformer_quant": get_quantization_config("FP8")(), # per-tensor (default) - # "transformer_quant": get_quantization_config("FP8")(granularity="channel"), # slower, higher accuracy - }, + "dit": {"quant_config": get_quantization_config("FP8")(granularity="channel")}, # slower, higher accuracy }, }) -gen.generate(request={"prompt": "A raccoon in sunflowers", "output": {"save_video": True}}) ``` Or run the example script: @@ -466,8 +469,11 @@ MS-SSIM gate on *your* config, especially when combining above unless your exact configuration has its own gate. Extra `torch.compile` options are passed through `torch_compile_kwargs` -(a dict), accepted by `VideoGenerator.from_pretrained(...)` and by the -CLI as a JSON string via `--torch-compile-kwargs`. Example (currently +(a dict), accepted by `VideoGenerator.from_pretrained(...)`. In a config +file or a CLI dotted override, set them at `engine.compile.backend`, +`fullgraph`, `mode`, and `dynamic`, and put any other `torch.compile` +kwargs in `engine.compile.extras` (for example +`--generator.engine.compile.mode reduce-overhead`). Example (currently **not** recommended — see the CUDA-graphs caveat above): ```python diff --git a/examples/inference/basic/basic_ltx2_3_distilled_i2v_typed.py b/examples/inference/basic/basic_ltx2_3_distilled_i2v_typed.py index b249ee88f..63c81fca3 100644 --- a/examples/inference/basic/basic_ltx2_3_distilled_i2v_typed.py +++ b/examples/inference/basic/basic_ltx2_3_distilled_i2v_typed.py @@ -2,11 +2,9 @@ """LTX-2.3 distilled image-to-video — typed API (``from_config`` / ``generate``). Identical generation behavior to ``basic_ltx2_3_distilled_i2v.py``, but -expressed through the newer typed surface (``GeneratorConfig`` / -``GenerationRequest``) instead of the ``from_pretrained(**legacy_kwargs)`` -bridge. The typed API is now the preferred entry point — the legacy -example still works but emits a ``DeprecationWarning`` for the LTX-2.3 -specific knobs. +expressed with the typed dataclasses (``GeneratorConfig`` / +``GenerationRequest``) instead of nested dicts and a ``PipelineConfig`` +object. Quick start ----------- @@ -42,28 +40,28 @@ Hardware notes The ``_inductor.shape_padding = False`` line below also avoids a ``pad_mm`` landmine on the same generation of cards. -Typed-API mapping (legacy kwarg ↔ typed field) ----------------------------------------------- -- ``num_gpus`` ↔ ``engine.num_gpus`` -- ``enable_torch_compile`` ↔ ``engine.compile.enabled`` -- ``enable_torch_compile_text_encoder`` ↔ ``engine.compile.text_encoder_enabled`` -- ``enable_torch_compile_vae`` ↔ ``engine.compile.vae_enabled`` -- ``torch_compile_kwargs`` ↔ ``engine.compile.backend/fullgraph/mode/dynamic`` -- ``torch_compile_kwargs_vae`` ↔ empty ``compile.vae_kwargs`` (inherits master) -- ``dit_cpu_offload`` ↔ ``engine.offload.dit`` -- ``text_encoder_cpu_offload`` ↔ ``engine.offload.text_encoder`` -- ``vae_cpu_offload`` ↔ ``engine.offload.vae`` -- ``ltx2_vae_tiling`` ↔ ``pipeline.vae_tiling`` -- ``ltx2_refine_enabled`` ↔ ``pipeline.preset_overrides["refine"]["enabled"]`` -- ``ltx2_refine_upsampler_path`` ↔ ``pipeline.components.upsampler_weights`` -- ``ltx2_refine_lora_path`` ↔ ``pipeline.ltx2.refine.lora_path`` -- ``ltx2_refine_num_inference_steps`` ↔ ``pipeline.preset_overrides["refine"]["num_inference_steps"]`` -- ``ltx2_refine_guidance_scale`` ↔ ``pipeline.preset_overrides["refine"]["guidance_scale"]`` -- ``ltx2_refine_add_noise`` ↔ ``pipeline.preset_overrides["refine"]["add_noise"]`` -- ``pipeline_config=PipelineConfig.from_pretrained(model_root)`` ↔ (no-op — ``PipelineConfig.from_kwargs`` already resolves the model-specific class from ``model_path``) -- ``pipeline_config.dit_config.quant_config = None`` ↔ leave ``engine.quantization`` unset -- ``ltx2_images`` / ``ltx2_image_crf`` ↔ ``request.extensions`` (LTX-2 specific, no - first-class typed field yet) +Recipe setting ↔ typed field +---------------------------- +- GPU count ↔ ``engine.num_gpus`` +- DiT compile ↔ ``engine.compile.enabled`` +- Text encoder compile ↔ ``engine.compile.text_encoder_enabled`` +- VAE compile ↔ ``engine.compile.vae_enabled`` +- ``torch.compile`` kwargs ↔ ``engine.compile.backend/fullgraph/mode/dynamic`` +- VAE ``torch.compile`` kwargs ↔ empty ``engine.compile.vae_kwargs`` (inherits the master kwargs) +- DiT CPU offload ↔ ``engine.offload.dit`` +- Text encoder CPU offload ↔ ``engine.offload.text_encoder`` +- VAE CPU offload ↔ ``engine.offload.vae`` +- VAE tiling ↔ ``pipeline.vae_tiling`` +- Refine stage on ↔ ``pipeline.preset_overrides["refine"]["enabled"]`` +- Refine upsampler ↔ ``pipeline.components.upsampler_weights`` +- Refine LoRA ↔ ``pipeline.ltx2.refine.lora_path`` +- Refine denoising steps ↔ ``pipeline.preset_overrides["refine"]["num_inference_steps"]`` +- Refine guidance scale ↔ ``pipeline.preset_overrides["refine"]["guidance_scale"]`` +- Refine noise injection ↔ ``pipeline.preset_overrides["refine"]["add_noise"]`` +- Model-specific ``PipelineConfig`` ↔ nothing to set: ``PipelineConfig.from_source`` builds the + registry class of ``model_path`` +- No DiT quantization ↔ leave ``engine.quantization`` unset +- Conditioning image and its CRF ↔ ``request.extensions["ltx2_images"]`` / ``["ltx2_image_crf"]`` (LTX-2 specific) """ from __future__ import annotations @@ -177,7 +175,7 @@ def main() -> None: # Keep DiT / text encoder / VAE resident on GPU — no CPU offload # for serving-style runs. ``image_encoder`` and # ``pin_cpu_memory`` are left at their schema defaults - # (matches the legacy example, which only set these three). + # (matches ``basic_ltx2_3_distilled_i2v.py``, which sets only these three). offload=OffloadConfig( dit=False, text_encoder=False, @@ -199,12 +197,12 @@ def main() -> None: ), ), pipeline=PipelineSelection( - # ``PipelineConfig.from_kwargs`` resolves the model-specific + # ``PipelineConfig.from_source`` resolves the model-specific # pipeline-config class from ``model_path`` automatically, so we # don't need to set ``components.pipeline_config_path`` — the # model-specific VAE precision / decoder defaults are picked up - # the same way the legacy example's - # ``PipelineConfig.from_pretrained(model_root)`` did them. + # the same way ``basic_ltx2_3_distilled_i2v.py``'s + # ``PipelineConfig.from_pretrained(model_root)`` picks them up. components=ComponentConfig(upsampler_weights=str(refine_upsampler_path), # Distilled has no refine LoRA — omit ``lora_path``. ), diff --git a/examples/inference/basic/basic_ltx2_distilled_fast_profile.py b/examples/inference/basic/basic_ltx2_distilled_fast_profile.py index 961cf80bc..a2f135bbf 100644 --- a/examples/inference/basic/basic_ltx2_distilled_fast_profile.py +++ b/examples/inference/basic/basic_ltx2_distilled_fast_profile.py @@ -236,7 +236,6 @@ def main() -> None: "components": {"upsampler_weights": str(refine_upsampler_path)}, "ltx2": {"refine": {"lora_path": ""}}, # keep refine LoRA disabled for distilled model "experimental": { - "refine_lora_path": "", # keep refine LoRA disabled in this repo's typed adapter "pipeline_config": pipeline_config, }, "vae_tiling": False, diff --git a/examples/inference/basic/basic_self_forcing_causal_wan2_2_t2v.py b/examples/inference/basic/basic_self_forcing_causal_wan2_2_t2v.py index 29fd4567a..1ac0e1ddb 100644 --- a/examples/inference/basic/basic_self_forcing_causal_wan2_2_t2v.py +++ b/examples/inference/basic/basic_self_forcing_causal_wan2_2_t2v.py @@ -35,7 +35,6 @@ def main(): "transformer_2_weights": "/mnt/sharefs/users/hao.zhang/wei/SFwan2.2_distill_self_forcing_release_cfg2/checkpoint-246_weight_only/generator_2_inference_transformer/", }, - "experimental": {"num_frame_per_block": 7}, }, }) diff --git a/examples/inference/optimizations/FastWan_QAD_TAEHV.py b/examples/inference/optimizations/FastWan_QAD_TAEHV.py index 8ac98a886..5c9833cca 100644 --- a/examples/inference/optimizations/FastWan_QAD_TAEHV.py +++ b/examples/inference/optimizations/FastWan_QAD_TAEHV.py @@ -142,17 +142,15 @@ def build_generator(args: argparse.Namespace) -> VideoGenerator: compile_enabled = not args.no_compile components = {} - experimental = {"pipeline_config": pipeline_config} if args.distilled_model: weights_path = resolve_distilled_weights(args.distilled_model) print(f"Using distilled weights: {args.distilled_model} -> {weights_path}") components["transformer_weights"] = weights_path - if args.taehv: - # Skip the in-pipeline VAE decode entirely: the pipeline returns raw - # latents, the Wan VAE is offloaded to CPU (and not compiled) since we - # decode with TAEHV in this script instead. - experimental["output_type"] = "latent" + # With TAEHV, skip the in-pipeline VAE decode entirely: the pipeline returns + # raw latents, the Wan VAE is offloaded to CPU (and not compiled) since we + # decode with TAEHV in this script instead. + output_type = "latent" if args.taehv else "pil" generator = VideoGenerator.from_config({ "model_path": model_id, @@ -176,7 +174,8 @@ def build_generator(args: argparse.Namespace) -> VideoGenerator: }, "pipeline": { "components": components, - "experimental": experimental, + "output_type": output_type, + "experimental": {"pipeline_config": pipeline_config}, }, }) return generator diff --git a/examples/inference/optimizations/fp8_wan2_1_1_3b.py b/examples/inference/optimizations/fp8_wan2_1_1_3b.py index f664334e9..74d0c5c67 100644 --- a/examples/inference/optimizations/fp8_wan2_1_1_3b.py +++ b/examples/inference/optimizations/fp8_wan2_1_1_3b.py @@ -80,9 +80,9 @@ def main(): taehv_model = load_taehv(args.taehv_checkpoint) if use_taehv else None - # transformer_quant needs a QuantizationConfig *instance* — the bare string - # is not resolved on the pipeline.experimental path. - extra = {} if args.bf16 else {"transformer_quant": get_quantization_config("FP8")(granularity=args.granularity)} + # A registry name cannot carry the FP8 granularity, so the FP8Config + # instance goes to the DiT config's quant_config through pipeline.dit. + dit_overrides = {} if args.bf16 else {"quant_config": get_quantization_config("FP8")(granularity=args.granularity)} generator = VideoGenerator.from_config({ "model_path": args.model, "engine": { @@ -101,10 +101,8 @@ def main(): }, }, "pipeline": { - "experimental": { - "output_type": "latent" if use_taehv else "pil", - **extra, - }, + "output_type": "latent" if use_taehv else "pil", + "dit": dit_overrides, }, }) diff --git a/examples/inference/optimizations/nvfp4_qat_wan2_1_1_3b.py b/examples/inference/optimizations/nvfp4_qat_wan2_1_1_3b.py index 7b8681550..7473da4f9 100644 --- a/examples/inference/optimizations/nvfp4_qat_wan2_1_1_3b.py +++ b/examples/inference/optimizations/nvfp4_qat_wan2_1_1_3b.py @@ -45,16 +45,12 @@ def main(): # Import after the env var so the platform picks up the selection. from fastvideo import VideoGenerator - from fastvideo.layers.quantization import get_quantization_config mode = "bf16" if args.bf16 else args.quant_method if args.compile: mode += "_compile" print(f"Mode: {mode.upper()}") - # transformer_quant needs a QuantizationConfig *instance* — the bare string - # is not resolved on the pipeline.experimental path. - extra = {} if args.bf16 else {"transformer_quant": get_quantization_config(args.quant_method)()} generator = VideoGenerator.from_config({ "model_path": args.model, "engine": { @@ -66,8 +62,10 @@ def main(): "text_encoder": True, }, "compile": {"enabled": args.compile}, + # transformer_quant takes a quantization registry name; resolution + # pins its config on the DiT config's quant_config. + "quantization": {"transformer_quant": None if args.bf16 else args.quant_method}, }, - "pipeline": {"experimental": extra}, }) prompt = ("A curious raccoon peers through a vibrant field of yellow sunflowers, its eyes " diff --git a/examples/train/configs/example.yaml b/examples/train/configs/example.yaml index 51dc03e66..970b7eaf2 100644 --- a/examples/train/configs/example.yaml +++ b/examples/train/configs/example.yaml @@ -6,7 +6,7 @@ # defaults. Unknown keys are silently ignored. # [FREE] — free-form dict passed as-is to the target class / method. # Keys depend on the _target_ class constructor / method_config. -# [RESOLVED] — parsed by PipelineConfig.from_kwargs(); auto-populated from +# [RESOLVED] — parsed by PipelineConfig.from_source(); auto-populated from # the model's config files. Only scalar overrides are useful. # ============================================================================== @@ -189,7 +189,7 @@ callbacks: # ------------------------------------------------------------------------------ # pipeline: [RESOLVED] -> PipelineConfig # -# Parsed by PipelineConfig.from_kwargs(). Most fields are auto-populated from +# Parsed by PipelineConfig.from_source(). Most fields are auto-populated from # the model's config files (vae_config, dit_config, text_encoder_configs, etc.). # Only scalar overrides are typically needed here. # ------------------------------------------------------------------------------ diff --git a/fastvideo/api/compat.py b/fastvideo/api/compat.py index 939902ca8..6a29be034 100644 --- a/fastvideo/api/compat.py +++ b/fastvideo/api/compat.py @@ -7,10 +7,8 @@ from dataclasses import fields, is_dataclass from pathlib import Path from typing import Any, get_args, get_type_hints -from fastvideo.api.inference_resolution import resolve_inference_config from fastvideo.api.overrides import apply_overrides, normalize_overrides from fastvideo.api.parser import config_to_dict, load_raw_config, parse_config -from fastvideo.api.resolution import ResolvedGeneratorConfig from fastvideo.api.request_metadata import ( EXPLICIT_PATHS_ATTR, bind_generation_request_raw, @@ -19,17 +17,11 @@ from fastvideo.api.request_metadata import ( ) from fastvideo.api.schema import ( FLAT_NAME, - CompileConfig, ContinuationState, GenerationRequest, GeneratorConfig, ) from fastvideo.api.sampling_param import SamplingParam -from fastvideo.fastvideo_args import FastVideoArgs -from fastvideo.pipelines.basic.ltx2.stage_overrides import ( - refine_preset_override_fields, - refine_stage_override_fields, -) _MISSING = object() REQUEST_BATCH_EXTRA_PASSTHROUGH_FIELDS = ( @@ -72,8 +64,6 @@ FROM_PRETRAINED_KWARGS = frozenset({ }) # torch.compile kwargs that map to first-class CompileConfig fields. _COMPILE_TYPED_KEYS = ("backend", "fullgraph", "mode", "dynamic") -# LTX-2 refine flat kwargs (init + per-request) known to FastVideoArgs. -_LTX2_REFINE_FLAT_KEYS = (refine_preset_override_fields() | refine_stage_override_fields()) def normalize_generator_config(config: GeneratorConfig | Mapping[str, Any], ) -> GeneratorConfig: @@ -109,15 +99,15 @@ def from_pretrained_kwargs_to_config( ) -> GeneratorConfig: """Build a ``GeneratorConfig`` from ``VideoGenerator.from_pretrained`` keyword arguments. - A keyword that a schema field declares as its flat name sets that field. ``torch_compile_kwargs`` is split across - ``engine.compile``, and the keywords without a typed field are kept in ``pipeline.experimental``. A keyword outside - ``FROM_PRETRAINED_KWARGS`` raises ``TypeError`` that names the typed path to use with ``from_config``. + A keyword that a schema field declares as its ``from_pretrained`` keyword sets that field. ``torch_compile_kwargs`` + is split across ``engine.compile``, and the keywords without a field are kept in ``pipeline.experimental``. A + keyword outside ``FROM_PRETRAINED_KWARGS`` raises ``TypeError``. """ unsupported = sorted(set(kwargs) - FROM_PRETRAINED_KWARGS) if unsupported: - paths = ", ".join(f"{key} -> {_typed_path_of_keyword(key, kwargs[key])}" for key in unsupported) - raise TypeError("VideoGenerator.from_pretrained(...) does not accept these keywords; pass them to " - f"VideoGenerator.from_config(...) at these config paths: {paths}") + raise TypeError(f"VideoGenerator.from_pretrained(...) does not accept {', '.join(unsupported)}. It accepts " + f"only these keywords: {', '.join(sorted(FROM_PRETRAINED_KWARGS))}. Pass every other setting " + "to VideoGenerator.from_config(...) at its config path.") raw: dict[str, Any] = {"model_path": model_path} for key, value in kwargs.items(): @@ -128,89 +118,13 @@ def from_pretrained_kwargs_to_config( _set_dotted_path(raw, ["engine", "compile", first_class], remaining.pop(first_class)) if remaining: _set_dotted_path(raw, ["engine", "compile", "extras"], remaining) - elif key in _FLAT_NAME_FIELDS: - _set_dotted_path(raw, _FLAT_NAME_FIELDS[key][0].split("."), value) + elif key in _FROM_PRETRAINED_FIELDS: + _set_dotted_path(raw, _FROM_PRETRAINED_FIELDS[key].split("."), value) else: _set_dotted_path(raw, ["pipeline", "experimental", key], deepcopy(value)) return parse_config(GeneratorConfig, raw) -def _typed_path_of_keyword(key: str, value: Any) -> str: - """The ``GeneratorConfig`` path that holds the setting of a flat ``FastVideoArgs`` keyword.""" - if key in _FLAT_NAME_FIELDS and not (key == "pipeline_config" and not isinstance(value, str)): - return _FLAT_NAME_FIELDS[key][0] - for prefix, section in _COMPONENT_OVERRIDE_PREFIXES.items(): - if key.startswith(prefix): - return f"pipeline.{section}.{key[len(prefix):]}" - return f"pipeline.experimental.{key}" - - -def generator_config_to_fastvideo_args( - config: GeneratorConfig | Mapping[str, Any] | ResolvedGeneratorConfig, ) -> FastVideoArgs: - """Resolve a ``GeneratorConfig`` and flatten it into a ``FastVideoArgs``. - - A config that is not resolved yet goes through :func:`resolve_inference_config` first. The keywords are the ones - that :func:`generator_kwargs` builds. - """ - resolved = config if isinstance(config, ResolvedGeneratorConfig) else resolve_inference_config(config) - return FastVideoArgs.from_kwargs(**generator_kwargs(resolved), resolved_config=resolved) - - -def generator_kwargs(resolved: ResolvedGeneratorConfig) -> dict[str, Any]: - """Flatten a resolved config into the flat keywords that build its ``PipelineConfig``. - - Every field of the resolved config that declares a flat name and holds a value other than ``None`` becomes the - keyword of that name. The paths in ``_SPECIALLY_MAPPED_PATHS`` are converted below; ``pipeline.preset_overrides`` - and then ``pipeline.experimental`` are applied last, so their keys win over the typed fields. - """ - normalized = resolved.to_config() - unsupported = [] - if normalized.pipeline.preset is not None: - unsupported.append("pipeline.preset") - if normalized.pipeline.preset_version is not None: - unsupported.append("pipeline.preset_version") - if normalized.pipeline.components.vae_weights is not None: - unsupported.append("pipeline.components.vae_weights") - if unsupported: - joined = ", ".join(unsupported) - raise NotImplementedError(f"VideoGenerator compatibility adapter does not support {joined} yet") - - kwargs: dict[str, Any] = {} - for flat_name, (dotted_path, _) in _FLAT_NAME_FIELDS.items(): - value = _read_dotted_path(normalized, dotted_path.split(".")) - if value is not _MISSING and value is not None: - kwargs[flat_name] = deepcopy(value) - kwargs["torch_compile_kwargs"] = _compile_config_to_torch_kwargs(normalized.engine.compile) - - quantization = normalized.engine.quantization - if quantization is not None and quantization.transformer_quant is not None: - # Resolve the typed quant name to a concrete ``QuantizationConfig`` - # instance and pin it on ``dit_config.quant_config``. The legacy - # path expected callers to do this themselves via - # ``pipeline_config.dit_config.quant_config = NVFP4Config()``; the - # typed surface accepts a string and does the wiring here so - # downstream code can rely on a single source of truth. - from fastvideo.layers.quantization import get_quantization_config - _resolved_quant_cls = get_quantization_config(quantization.transformer_quant) - kwargs["transformer_quant"] = _resolved_quant_cls() - - for prefix, section in _COMPONENT_OVERRIDE_PREFIXES.items(): - for field_name, value in getattr(normalized.pipeline, section).items(): - kwargs[f"{prefix}{field_name}"] = deepcopy(value) - - preset_overrides = deepcopy(normalized.pipeline.preset_overrides) - refine = preset_overrides.pop("refine", None) - if isinstance(refine, Mapping): - for key in _LTX2_REFINE_FLAT_KEYS: - if key in refine: - kwargs[f"ltx2_refine_{key}"] = refine[key] - if "enabled" in refine: - kwargs["refine_enabled"] = refine["enabled"] - kwargs.update(preset_overrides) - kwargs.update(deepcopy(normalized.pipeline.experimental)) - return kwargs - - def normalize_generation_request(request: GenerationRequest | Mapping[str, Any], ) -> GenerationRequest: normalized = (request if isinstance(request, GenerationRequest) else parse_config(GenerationRequest, request)) @@ -276,8 +190,8 @@ def _looks_like_run_or_serve_config(raw: Mapping[str, Any]) -> bool: return isinstance(raw.get("generator"), Mapping) -def _schema_fields(config_type: type, prefix: str = "") -> Iterator[tuple[str, Any, Any]]: - """Yield ``(dotted path, field, annotation)`` for every field under ``config_type`` that is not a nested config. +def _schema_fields(config_type: type, prefix: str = "") -> Iterator[tuple[str, Any]]: + """Yield ``(dotted path, field)`` for every field under ``config_type`` that is not a nested config. A field whose type is a dataclass, or an optional dataclass, is a nested config and is walked into. """ @@ -289,55 +203,14 @@ def _schema_fields(config_type: type, prefix: str = "") -> Iterator[tuple[str, A if nested: yield from _schema_fields(nested[0], f"{dotted_path}.") else: - yield dotted_path, config_field, annotation + yield dotted_path, config_field -# Flat keyword name -> (dotted path, annotation) for every GeneratorConfig field that declares a flat name. -_FLAT_NAME_FIELDS: dict[str, tuple[str, Any]] = { - config_field.metadata[FLAT_NAME]: (dotted_path, annotation) - for dotted_path, config_field, annotation in _schema_fields(GeneratorConfig) if FLAT_NAME in config_field.metadata +# ``from_pretrained`` keyword -> dotted path of the GeneratorConfig field that declares it. +_FROM_PRETRAINED_FIELDS: dict[str, str] = { + config_field.metadata[FLAT_NAME]: dotted_path + for dotted_path, config_field in _schema_fields(GeneratorConfig) if FLAT_NAME in config_field.metadata } -# GeneratorConfig fields without a flat name, and how generator_config_to_fastvideo_args carries each one. -_SPECIALLY_MAPPED_PATHS: dict[str, str] = { - **{ - f"engine.compile.{key}": "merged into torch_compile_kwargs" - for key in (*_COMPILE_TYPED_KEYS, "extras") - }, - "engine.quantization.transformer_quant": "resolved to a QuantizationConfig instance", - "pipeline.preset": "not supported", - "pipeline.preset_version": "not supported", - "pipeline.components.vae_weights": "not supported", - "pipeline.ltx2.refine.image_crf": "no flat keyword; copied from pipeline.preset_overrides.refine", - "pipeline.ltx2.refine.video_position_offset_sec": "no flat keyword; copied from pipeline.preset_overrides.refine", - "pipeline.dit": "keys passed as dit_config.", - "pipeline.vae": "keys passed as vae_config.", - "pipeline.preset_overrides": "keys passed as flat keywords; refine keys renamed to ltx2_refine_*", - "pipeline.experimental": "keys passed as flat keywords", -} -# Flat keyword prefix for a component config override -> the PipelineSelection dict that holds the overrides. -_COMPONENT_OVERRIDE_PREFIXES = { - "dit_config.": "dit", - "vae_config.": "vae", -} - - -def _compile_config_to_torch_kwargs(compile_config: CompileConfig, ) -> dict[str, Any]: - """Flatten typed ``CompileConfig`` back to a ``torch_compile_kwargs`` - dict that the legacy ``FastVideoArgs`` path still expects. - - Typed first-class fields (:attr:`backend`, :attr:`fullgraph`, - :attr:`mode`, :attr:`dynamic`) are only emitted when the user set - them explicitly (non-``None``). ``extras`` is merged on top for any - uncommon kwargs. - """ - out: dict[str, Any] = {} - for key in _COMPILE_TYPED_KEYS: - value = getattr(compile_config, key) - if value is not None: - out[key] = value - if compile_config.extras: - out.update(deepcopy(compile_config.extras)) - return out def request_to_batch_extra(request: GenerationRequest) -> dict[str, Any]: @@ -537,8 +410,6 @@ __all__ = [ "explicit_request_raw", "explicit_request_updates", "from_pretrained_kwargs_to_config", - "generator_config_to_fastvideo_args", - "generator_kwargs", "load_generator_config_from_file", "normalize_generation_request", "normalize_generator_config", diff --git a/fastvideo/api/device_policy.py b/fastvideo/api/device_policy.py index 43b76e417..9b55f3f60 100644 --- a/fastvideo/api/device_policy.py +++ b/fastvideo/api/device_policy.py @@ -17,8 +17,8 @@ from fastvideo.logger import init_logger logger = init_logger(__name__) -# Offload settings that trade device memory for host memory, by flat name. All of them are a loss on a device whose -# host and device memory are the same physical pool. +# Offload settings that trade device memory for host memory, by the flag name that loaders and log messages use. All +# of them are a loss on a device whose host and device memory are the same physical pool. UNIFIED_MEMORY_OFFLOAD_PATHS = { "dit_layerwise_offload": "engine.offload.dit_layerwise", "dit_cpu_offload": "engine.offload.dit", @@ -125,7 +125,7 @@ def finalize_device_offload_policy(resolved_config: ResolvedGeneratorConfig, if lazy_module_load: logger.info( "Enabling lazy_module_load: %s has unified memory, so encoder, DiT, and VAEs cannot stay " - "resident together. Pass --no-lazy-module-load to keep every component loaded.", + "resident together. Set engine.offload.lazy_module_load to false to keep every component loaded.", _device_name(device_id), ) return resolve_device_offload_conflicts(resolved_config) diff --git a/fastvideo/api/flat_name_fallback.py b/fastvideo/api/flat_name_fallback.py deleted file mode 100644 index 3fe7a5516..000000000 --- a/fastvideo/api/flat_name_fallback.py +++ /dev/null @@ -1,1401 +0,0 @@ -# SPDX-License-Identifier: Apache-2.0 -"""Flat ``FastVideoArgs`` and ``TrainingArgs`` attribute names on a ``ResolvedGeneratorConfig``. - -Runtime code that still reads ``fastvideo_args.`` receives a ``ResolvedGeneratorConfig``. An attribute -that is not a field of the typed tree reaches :func:`read_flat_name`, which looks the name up in ``FLAT_TO_TYPED`` -and returns the value that ``FastVideoArgs`` or ``TrainingArgs`` held for the same input: - -- ``typed``: the value at the typed path. A ``None`` value stands for ``none_value``, the ``FastVideoArgs`` default - (``cli_none_value`` on the training and preprocessing roots, whose runs used the argparse defaults). ``convert`` - names the flat format, such as an enum or a comma-separated string. -- ``pipeline_config``: the materialized ``PipelineConfig``. -- ``property``: a read-only property of the resolved config. -- ``derived``: a pure function of a typed value. -- ``runtime_state``: mutable state behind ``RUNTIME_STATE_NAMES``, shared by every config that ``with_override`` - derives from the same resolution. -- ``removed``: a name without a typed field; ``fallback`` says which input still supplies the flat value. - -``FLAT_TO_TYPED`` and ``PIPELINE_CONFIG_TYPED_HOMES`` are generated from ``FastVideoArgs``, ``TrainingArgs``, and the -typed schema, together with ``flat_to_typed.json``. This module goes away with the flat names. -""" -from __future__ import annotations - -from collections.abc import Mapping -from copy import deepcopy -from typing import Any - -from fastvideo.api.resolution import _lookup, _Struct, _to_config, _to_plain - -# Names of runtime state that code assigns or mutates in place after resolution. -RUNTIME_STATE_NAMES = frozenset({"model_paths", "model_loaded", "ray_placement_group", "ray_runtime_env"}) -# Root config classes whose runs took their values from the FastVideoArgs and TrainingArgs command line. -_COMMAND_LINE_ROOTS = frozenset({"TrainingRunConfig", "PreprocessRunConfig"}) -# Generic refine keys under pipeline.experimental or pipeline.preset_overrides, and the typed path each one sets. -GENERIC_REFINE_PATHS = { - "refine_enabled": "pipeline.ltx2.refine.enabled", - "refine_upsampler_path": "pipeline.components.upsampler_weights", - "refine_transformer_path": "pipeline.ltx2.refine.transformer_path", - "refine_lora_path": "pipeline.ltx2.refine.lora_path", - "refine_num_inference_steps": "pipeline.ltx2.refine.num_inference_steps", - "refine_guidance_scale": "pipeline.ltx2.refine.guidance_scale", - "refine_add_noise": "pipeline.ltx2.refine.add_noise", - "refine_noise_path": "pipeline.ltx2.refine.noise_path", - "refine_audio_noise_path": "pipeline.ltx2.refine.audio_noise_path", -} - -# BEGIN GENERATED FLAT_TO_TYPED (gen_flat_to_typed.py) -FLAT_TO_TYPED: dict[str, dict[str, Any]] = { - 'VSA_cache_tile_buf': { - 'kind': 'typed', - 'path': 'training.vsa.cache_tile_buf', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'VSA_decay_interval_steps': { - 'kind': 'typed', - 'path': 'training.vsa.decay_interval_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'VSA_decay_rate': { - 'kind': 'typed', - 'path': 'training.vsa.decay_rate', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'VSA_sparsity': { - 'kind': 'typed', - 'none_value': 0.0, - 'path': 'engine.attention.vsa_sparsity', - 'source': 'FastVideoArgs' - }, - 'VSA_tile_size': { - 'kind': 'typed', - 'none_value': 256, - 'path': 'engine.attention.vsa_tile_size', - 'source': 'FastVideoArgs' - }, - 'attention_backend': { - 'kind': 'typed', - 'path': 'engine.attention.backend', - 'source': 'FastVideoArgs' - }, - 'betas': { - 'convert': 'comma_string', - 'kind': 'typed', - 'path': 'training.optimizer.betas', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'boundary_ratio': { - 'kind': 'typed', - 'none_value': 0.875, - 'path': 'pipeline.boundary_ratio', - 'source': 'FastVideoArgs' - }, - 'checkpoints_total_limit': { - 'kind': 'typed', - 'path': 'training.checkpoint.checkpoints_total_limit', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'context_noise': { - 'kind': 'typed', - 'path': 'training.self_forcing.context_noise', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'data_path': { - 'kind': 'typed', - 'path': 'training.data.data_path', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'dataloader_num_workers': { - 'kind': 'typed', - 'path': 'training.data.dataloader_num_workers', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'dfake_gen_update_ratio': { - 'kind': 'typed', - 'path': 'training.self_forcing.dfake_gen_update_ratio', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'disable_autocast': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.disable_autocast', - 'source': 'FastVideoArgs' - }, - 'dist_timeout': { - 'kind': 'typed', - 'path': 'engine.parallelism.dist_timeout', - 'source': 'FastVideoArgs' - }, - 'distill_cfg': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'distributed_executor_backend': { - 'kind': 'typed', - 'none_value': 'mp', - 'path': 'engine.execution_backend', - 'source': 'FastVideoArgs' - }, - 'dit_cpu_offload': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.offload.dit', - 'source': 'FastVideoArgs' - }, - 'dit_layerwise_offload': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.offload.dit_layerwise', - 'source': 'FastVideoArgs' - }, - 'ema_decay': { - 'kind': 'typed', - 'path': 'training.ema.decay', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'ema_start_step': { - 'kind': 'typed', - 'path': 'training.ema.start_step', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'enable_gradient_checkpointing_type': { - 'kind': 'typed', - 'path': 'training.model.enable_gradient_checkpointing_type', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'enable_gradient_masking': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'enable_stage_verification': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.enable_stage_verification', - 'source': 'FastVideoArgs' - }, - 'enable_torch_compile': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.compile.enabled', - 'source': 'FastVideoArgs' - }, - 'enable_torch_compile_audio_vae': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.compile.audio_vae_enabled', - 'source': 'FastVideoArgs' - }, - 'enable_torch_compile_text_encoder': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.compile.text_encoder_enabled', - 'source': 'FastVideoArgs' - }, - 'enable_torch_compile_vae': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.compile.vae_enabled', - 'source': 'FastVideoArgs' - }, - 'fake_score_betas': { - 'convert': 'comma_string', - 'kind': 'typed', - 'path': 'training.distillation.fake_score_betas', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'fake_score_learning_rate': { - 'kind': 'typed', - 'path': 'training.distillation.fake_score_learning_rate', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'fake_score_lr_scheduler': { - 'kind': 'typed', - 'path': 'training.distillation.fake_score_lr_scheduler', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'fake_score_model_path': { - 'kind': 'typed', - 'path': 'training.distillation.fake_score_model_path', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'fsdp_sharding_startegy': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'generator_update_interval': { - 'kind': 'typed', - 'path': 'training.distillation.generator_update_interval', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'gradient_accumulation_steps': { - 'kind': 'typed', - 'path': 'training.loop.gradient_accumulation_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'gradient_mask_last_n_frames': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'group_frame': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'group_resolution': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'h3_sequential_load': { - 'kind': 'typed', - 'path': 'pipeline.minimax_h3.sequential_load', - 'source': 'FastVideoArgs' - }, - 'hsdp_replicate_dim': { - 'kind': 'typed', - 'none_value': 1, - 'path': 'engine.parallelism.hsdp_replicate_dim', - 'source': 'FastVideoArgs' - }, - 'hsdp_shard_dim': { - 'kind': 'typed', - 'none_value': -1, - 'path': 'engine.parallelism.hsdp_shard_dim', - 'source': 'FastVideoArgs' - }, - 'hunyuan_teacher_disable_cfg': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'image_encoder_cpu_offload': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.offload.image_encoder', - 'source': 'FastVideoArgs' - }, - 'independent_first_frame': { - 'kind': 'typed', - 'path': 'training.self_forcing.independent_first_frame', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'inference_mode': { - 'kind': 'property', - 'note': 'not (mode in (FINETUNING, DISTILLATION))', - 'path': 'inference_mode', - 'source': 'FastVideoArgs' - }, - 'inference_torch_compile': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.compile.regional', - 'source': 'FastVideoArgs' - }, - 'init_weights_from_safetensors': { - 'cli_none_value': None, - 'kind': 'typed', - 'none_value': '', - 'path': 'pipeline.components.transformer_weights', - 'source': 'FastVideoArgs' - }, - 'init_weights_from_safetensors_2': { - 'cli_none_value': None, - 'kind': 'typed', - 'none_value': '', - 'path': 'pipeline.components.transformer_2_weights', - 'source': 'FastVideoArgs' - }, - 'last_step_only': { - 'kind': 'typed', - 'path': 'training.self_forcing.last_step_only', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lazy_module_load': { - 'kind': 'typed', - 'path': 'engine.offload.lazy_module_load', - 'source': 'FastVideoArgs' - }, - 'learning_rate': { - 'kind': 'typed', - 'path': 'training.optimizer.learning_rate', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'linear_quadratic_threshold': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'linear_range': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'log_validation': { - 'kind': 'typed', - 'path': 'training.validation.enabled', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'log_visualization': { - 'kind': 'typed', - 'path': 'training.validation.log_visualization', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'logit_mean': { - 'kind': 'typed', - 'path': 'training.model.logit_mean', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'logit_std': { - 'kind': 'typed', - 'path': 'training.model.logit_std', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lora_alpha': { - 'kind': 'typed', - 'path': 'training.lora.alpha', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lora_nickname': { - 'kind': 'typed', - 'none_value': 'default', - 'path': 'pipeline.components.lora_nickname', - 'source': 'FastVideoArgs' - }, - 'lora_path': { - 'kind': 'typed', - 'path': 'pipeline.components.lora_path', - 'source': 'FastVideoArgs' - }, - 'lora_rank': { - 'kind': 'typed', - 'path': 'training.lora.rank', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lora_strength': { - 'kind': 'typed', - 'none_value': 1.0, - 'path': 'pipeline.components.lora_strength', - 'source': 'FastVideoArgs' - }, - 'lora_target_modules': { - 'kind': 'typed', - 'path': 'pipeline.components.lora_target_modules', - 'source': 'FastVideoArgs' - }, - 'lora_training': { - 'kind': 'typed', - 'path': 'training.lora.enabled', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lr_num_cycles': { - 'kind': 'typed', - 'path': 'training.optimizer.lr_num_cycles', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lr_power': { - 'kind': 'typed', - 'path': 'training.optimizer.lr_power', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lr_scheduler': { - 'kind': 'typed', - 'path': 'training.optimizer.lr_scheduler', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'lr_warmup_steps': { - 'kind': 'typed', - 'path': 'training.optimizer.lr_warmup_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'ltx2_audio_latent_path': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.audio_latent_path', - 'source': 'FastVideoArgs' - }, - 'ltx2_first_frame_conditioning_p': { - 'kind': 'typed', - 'path': 'training.model.ltx2_first_frame_conditioning_p', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'ltx2_initial_latent_path': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.initial_latent_path', - 'source': 'FastVideoArgs' - }, - 'ltx2_legacy_native_noise_order': { - 'kind': 'typed', - 'none_value': False, - 'path': 'pipeline.ltx2.legacy_native_noise_order', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_add_noise': { - 'kind': 'typed', - 'none_value': True, - 'path': 'pipeline.ltx2.refine.add_noise', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_audio_noise_path': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.refine.audio_noise_path', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_enabled': { - 'kind': 'typed', - 'none_value': False, - 'path': 'pipeline.ltx2.refine.enabled', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_guidance_scale': { - 'kind': 'typed', - 'none_value': 1.0, - 'path': 'pipeline.ltx2.refine.guidance_scale', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_lora_path': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.refine.lora_path', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_noise_path': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.refine.noise_path', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_num_inference_steps': { - 'kind': 'typed', - 'none_value': 3, - 'path': 'pipeline.ltx2.refine.num_inference_steps', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_transformer_path': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.refine.transformer_path', - 'source': 'FastVideoArgs' - }, - 'ltx2_refine_upsampler_path': { - 'kind': 'typed', - 'path': 'pipeline.components.upsampler_weights', - 'source': 'FastVideoArgs' - }, - 'ltx2_use_distilled_sigmas': { - 'kind': 'typed', - 'none_value': True, - 'path': 'pipeline.ltx2.use_distilled_sigmas', - 'source': 'FastVideoArgs' - }, - 'ltx2_vae_spatial_tile_overlap_in_pixels': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.vae_spatial_tile_overlap_in_pixels', - 'source': 'FastVideoArgs' - }, - 'ltx2_vae_spatial_tile_size_in_pixels': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.vae_spatial_tile_size_in_pixels', - 'source': 'FastVideoArgs' - }, - 'ltx2_vae_temporal_tile_overlap_in_frames': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.vae_temporal_tile_overlap_in_frames', - 'source': 'FastVideoArgs' - }, - 'ltx2_vae_temporal_tile_size_in_frames': { - 'kind': 'typed', - 'path': 'pipeline.ltx2.vae_temporal_tile_size_in_frames', - 'source': 'FastVideoArgs' - }, - 'ltx2_vae_tiling': { - 'kind': 'typed', - 'path': 'pipeline.vae_tiling', - 'source': 'FastVideoArgs' - }, - 'master_port': { - 'kind': 'typed', - 'path': 'engine.parallelism.master_port', - 'source': 'FastVideoArgs' - }, - 'master_weight_type': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'max_grad_norm': { - 'kind': 'typed', - 'path': 'training.optimizer.max_grad_norm', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'max_timestep_ratio': { - 'kind': 'typed', - 'path': 'training.distillation.max_timestep_ratio', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'max_train_steps': { - 'kind': 'typed', - 'path': 'training.loop.max_train_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'min_lr_ratio': { - 'kind': 'typed', - 'path': 'training.optimizer.min_lr_ratio', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'min_timestep_ratio': { - 'kind': 'typed', - 'path': 'training.distillation.min_timestep_ratio', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'mixed_precision': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'moba_config': { - 'kind': 'typed', - 'none_value': {}, - 'path': 'engine.attention.moba_config', - 'source': 'FastVideoArgs' - }, - 'moba_config_path': { - 'kind': 'typed', - 'path': 'engine.attention.moba_config_path', - 'source': 'FastVideoArgs' - }, - 'mode': { - 'convert': 'execution_mode', - 'kind': 'typed', - 'path': 'mode', - 'source': 'FastVideoArgs' - }, - 'mode_scale': { - 'kind': 'typed', - 'path': 'training.model.mode_scale', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'model_loaded': { - 'default': { - 'transformer': True, - 'upsampler': True, - 'vae': True - }, - 'kind': 'runtime_state', - 'path': 'ComposedPipelineBase.model_loaded (pipeline object)', - 'source': 'FastVideoArgs' - }, - 'model_path': { - 'kind': 'typed', - 'path': 'model_path', - 'source': 'FastVideoArgs' - }, - 'model_paths': { - 'default': {}, - 'kind': 'runtime_state', - 'path': 'ComposedPipelineBase.model_paths (pipeline object)', - 'source': 'FastVideoArgs' - }, - 'multi_phased_distill_schedule': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'not_apply_cfg_solver': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_euler_timesteps': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_frame_per_block': { - 'kind': 'typed', - 'path': 'training.self_forcing.num_frame_per_block', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_frames': { - 'kind': 'typed', - 'path': 'training.data.num_frames', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_gpus': { - 'kind': 'typed', - 'none_value': 1, - 'path': 'engine.num_gpus', - 'source': 'FastVideoArgs' - }, - 'num_height': { - 'kind': 'typed', - 'path': 'training.data.num_height', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_latent_t': { - 'kind': 'typed', - 'path': 'training.data.num_latent_t', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_train_epochs': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'num_width': { - 'kind': 'typed', - 'path': 'training.data.num_width', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'output_dir': { - 'kind': 'typed', - 'path': 'training.checkpoint.output_dir', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'output_type': { - 'kind': 'typed', - 'none_value': 'pil', - 'path': 'pipeline.output_type', - 'source': 'FastVideoArgs' - }, - 'override_pipeline_cls_name': { - 'kind': 'typed', - 'path': 'pipeline.components.override_pipeline_cls_name', - 'source': 'FastVideoArgs' - }, - 'override_text_encoder_quant': { - 'kind': 'typed', - 'path': 'engine.quantization.text_encoder_quant', - 'source': 'FastVideoArgs' - }, - 'override_text_encoder_safetensors': { - 'kind': 'typed', - 'path': 'pipeline.components.text_encoder_weights', - 'source': 'FastVideoArgs' - }, - 'override_transformer_cls_name': { - 'kind': 'typed', - 'path': 'pipeline.components.override_transformer_cls_name', - 'source': 'FastVideoArgs' - }, - 'pin_cpu_memory': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.offload.pin_cpu_memory', - 'source': 'FastVideoArgs' - }, - 'pipeline_config': { - 'kind': 'pipeline_config', - 'note': 'resolved_config.pipeline_config, the frozen model definition. Read a ' - 'typed-home attribute (see pipeline_config_typed_homes) from its typed path.', - 'path': 'pipeline_config', - 'source': 'FastVideoArgs' - }, - 'precondition_outputs': { - 'kind': 'typed', - 'path': 'training.model.precondition_outputs', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'pred_decay_type': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'pred_decay_weight': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'preprocess_config': { - 'kind': 'typed', - 'note': 'the preprocess section of PreprocessRunConfig; None on the other roots', - 'other_roots_value': None, - 'path': 'preprocess', - 'roots': ['PreprocessRunConfig'], - 'source': 'FastVideoArgs' - }, - 'pretrained_model_name_or_path': { - 'kind': 'typed', - 'path': 'model_path', - 'source': 'TrainingArgs' - }, - 'prompt_txt': { - 'fallback': 'experimental', - 'kind': 'removed', - 'note': 'requests carry inputs.prompt_path; the fallback reads ' - 'pipeline.experimental.prompt_txt', - 'path': 'request inputs.prompt_path', - 'source': 'FastVideoArgs' - }, - 'ray_placement_group': { - 'default': None, - 'kind': 'runtime_state', - 'path': 'RayDistributedExecutor (returned by initialize_ray_cluster)', - 'source': 'FastVideoArgs' - }, - 'ray_runtime_env': { - 'default': None, - 'kind': 'runtime_state', - 'note': 'initialized from pipeline.experimental.ray_runtime_env', - 'path': 'RayDistributedExecutor constructor argument', - 'source': 'FastVideoArgs' - }, - 'real_score_guidance_scale': { - 'kind': 'typed', - 'path': 'training.distillation.real_score_guidance_scale', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'real_score_model_path': { - 'kind': 'typed', - 'path': 'training.distillation.real_score_model_path', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'refine_add_noise': { - 'fallback': 'generic_refine_alias', - 'kind': 'removed', - 'note': 'generic alias of the LTX-2 refine field; the fallback returns the alias value ' - 'that pipeline.experimental / pipeline.preset_overrides wrote, else None', - 'path': 'pipeline.ltx2.refine.add_noise', - 'source': 'FastVideoArgs' - }, - 'refine_audio_noise_path': { - 'fallback': - 'generic_refine_alias', - 'kind': - 'removed', - 'note': - 'generic alias of the LTX-2 refine field; the fallback returns the ' - 'alias value that pipeline.experimental / pipeline.preset_overrides ' - 'wrote, else None', - 'path': - 'pipeline.ltx2.refine.audio_noise_path', - 'source': - 'FastVideoArgs' - }, - 'refine_enabled': { - 'fallback': 'generic_refine_alias', - 'kind': 'removed', - 'note': 'generic alias of the LTX-2 refine field; the fallback returns the alias value ' - 'that pipeline.experimental / pipeline.preset_overrides wrote, else None', - 'path': 'pipeline.ltx2.refine.enabled', - 'source': 'FastVideoArgs' - }, - 'refine_guidance_scale': { - 'fallback': - 'generic_refine_alias', - 'kind': - 'removed', - 'note': - 'generic alias of the LTX-2 refine field; the fallback returns the alias ' - 'value that pipeline.experimental / pipeline.preset_overrides wrote, else ' - 'None', - 'path': - 'pipeline.ltx2.refine.guidance_scale', - 'source': - 'FastVideoArgs' - }, - 'refine_lora_path': { - 'fallback': 'generic_refine_alias', - 'kind': 'removed', - 'note': 'generic alias of the LTX-2 refine field; the fallback returns the alias value ' - 'that pipeline.experimental / pipeline.preset_overrides wrote, else None', - 'path': 'pipeline.ltx2.refine.lora_path', - 'source': 'FastVideoArgs' - }, - 'refine_noise_path': { - 'fallback': - 'generic_refine_alias', - 'kind': - 'removed', - 'note': - 'generic alias of the LTX-2 refine field; the fallback returns the alias ' - 'value that pipeline.experimental / pipeline.preset_overrides wrote, else ' - 'None', - 'path': - 'pipeline.ltx2.refine.noise_path', - 'source': - 'FastVideoArgs' - }, - 'refine_num_inference_steps': { - 'fallback': - 'generic_refine_alias', - 'kind': - 'removed', - 'note': - 'generic alias of the LTX-2 refine field; the fallback returns the ' - 'alias value that pipeline.experimental / pipeline.preset_overrides ' - 'wrote, else None', - 'path': - 'pipeline.ltx2.refine.num_inference_steps', - 'source': - 'FastVideoArgs' - }, - 'refine_transformer_path': { - 'fallback': - 'generic_refine_alias', - 'kind': - 'removed', - 'note': - 'generic alias of the LTX-2 refine field; the fallback returns the ' - 'alias value that pipeline.experimental / pipeline.preset_overrides ' - 'wrote, else None', - 'path': - 'pipeline.ltx2.refine.transformer_path', - 'source': - 'FastVideoArgs' - }, - 'refine_upsampler_path': { - 'fallback': - 'generic_refine_alias', - 'kind': - 'removed', - 'note': - 'generic alias of the LTX-2 refine field; the fallback returns the alias ' - 'value that pipeline.experimental / pipeline.preset_overrides wrote, else ' - 'None', - 'path': - 'pipeline.components.upsampler_weights', - 'source': - 'FastVideoArgs' - }, - 'resume_from_checkpoint': { - 'kind': 'typed', - 'path': 'training.checkpoint.resume_from_checkpoint', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'revision': { - 'kind': 'typed', - 'path': 'revision', - 'source': 'FastVideoArgs' - }, - 'same_step_across_blocks': { - 'kind': 'typed', - 'path': 'training.self_forcing.same_step_across_blocks', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'scale_lr': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'scheduler_type': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'seed': { - 'kind': 'typed', - 'path': 'training.data.seed', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'selective_checkpointing': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'simulate_generator_forward': { - 'kind': 'typed', - 'path': 'training.distillation.simulate_generator_forward', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'sp_size': { - 'kind': 'typed', - 'none_value': -1, - 'path': 'engine.parallelism.sp_size', - 'source': 'FastVideoArgs' - }, - 'taeh3_checkpoint': { - 'kind': 'typed', - 'path': 'pipeline.minimax_h3.taeh3_checkpoint', - 'source': 'FastVideoArgs' - }, - 'taeh3_chunk_size': { - 'kind': 'typed', - 'none_value': 5, - 'path': 'pipeline.minimax_h3.taeh3_chunk_size', - 'source': 'FastVideoArgs' - }, - 'text_encoder_cpu_offload': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.offload.text_encoder', - 'source': 'FastVideoArgs' - }, - 'torch_compile_kwargs': { - 'derive': 'torch_compile_kwargs', - 'kind': 'derived', - 'note': 'backend/fullgraph/mode/dynamic that are not None, then extras; ' - 'fastvideo.api.compat._compile_config_to_torch_kwargs', - 'path': 'engine.compile', - 'source': 'FastVideoArgs' - }, - 'torch_compile_kwargs_audio_vae': { - 'kind': 'typed', - 'none_value': {}, - 'path': 'engine.compile.audio_vae_kwargs', - 'source': 'FastVideoArgs' - }, - 'torch_compile_kwargs_dit': { - 'kind': 'typed', - 'none_value': {}, - 'path': 'engine.compile.dit_kwargs', - 'source': 'FastVideoArgs' - }, - 'torch_compile_kwargs_text_encoder': { - 'kind': 'typed', - 'none_value': {}, - 'path': 'engine.compile.text_encoder_kwargs', - 'source': 'FastVideoArgs' - }, - 'torch_compile_kwargs_vae': { - 'kind': 'typed', - 'none_value': {}, - 'path': 'engine.compile.vae_kwargs', - 'source': 'FastVideoArgs' - }, - 'tp_size': { - 'kind': 'typed', - 'none_value': -1, - 'path': 'engine.parallelism.tp_size', - 'source': 'FastVideoArgs' - }, - 'tracker_project_name': { - 'kind': 'typed', - 'path': 'training.tracker.project_name', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'trackers': { - 'kind': 'typed', - 'path': 'training.tracker.trackers', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'train_batch_size': { - 'kind': 'typed', - 'path': 'training.data.train_batch_size', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'train_sp_batch_size': { - 'kind': 'typed', - 'path': 'training.data.train_sp_batch_size', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'training_cfg_rate': { - 'kind': 'typed', - 'path': 'training.data.training_cfg_rate', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'training_state_checkpointing_steps': { - 'kind': 'typed', - 'path': 'training.checkpoint.training_state_checkpointing_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'transformer_quant': { - 'derive': 'transformer_quant', - 'kind': 'derived', - 'note': 'the QuantizationConfig instance for the typed name; materialization pins it ' - 'on pipeline_config.dit_config.quant_config', - 'path': 'engine.quantization.transformer_quant', - 'source': 'FastVideoArgs' - }, - 'trust_remote_code': { - 'kind': 'typed', - 'none_value': False, - 'path': 'trust_remote_code', - 'source': 'FastVideoArgs' - }, - 'use_ema': { - 'kind': 'typed', - 'path': 'training.ema.enabled', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'use_fsdp_inference': { - 'kind': 'typed', - 'none_value': False, - 'path': 'engine.use_fsdp_inference', - 'source': 'FastVideoArgs' - }, - 'vae_cpu_offload': { - 'kind': 'typed', - 'none_value': True, - 'path': 'engine.offload.vae', - 'source': 'FastVideoArgs' - }, - 'vae_parallel_decode': { - 'kind': 'typed', - 'none_value': False, - 'path': 'pipeline.minimax_h3.vae_parallel_decode', - 'source': 'FastVideoArgs' - }, - 'vae_parallel_decode_strategy': { - 'kind': 'typed', - 'path': 'pipeline.minimax_h3.vae_parallel_decode_strategy', - 'source': 'FastVideoArgs' - }, - 'vae_parallel_encode': { - 'kind': 'typed', - 'none_value': False, - 'path': 'pipeline.minimax_h3.vae_parallel_encode', - 'source': 'FastVideoArgs' - }, - 'validation_dataset_file': { - 'kind': 'typed', - 'path': 'training.validation.dataset_file', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'validation_guidance_scale': { - 'convert': 'string', - 'kind': 'typed', - 'path': 'training.validation.guidance_scale', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'validation_preprocessed_path': { - 'kind': 'removed', - 'note': 'no readers; no typed field', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'validation_sampling_steps': { - 'convert': 'comma_string', - 'kind': 'typed', - 'path': 'training.validation.sampling_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'validation_steps': { - 'kind': 'typed', - 'path': 'training.validation.every_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'video_decode_backend': { - 'kind': 'typed', - 'none_value': 'h3-vae', - 'path': 'pipeline.minimax_h3.video_decode_backend', - 'source': 'FastVideoArgs' - }, - 'visualization_steps': { - 'kind': 'typed', - 'path': 'training.validation.visualization_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'wandb_run_name': { - 'kind': 'typed', - 'path': 'training.tracker.run_name', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'warp_denoising_step': { - 'kind': 'typed', - 'path': 'training.distillation.warp_denoising_step', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'weight_decay': { - 'kind': 'typed', - 'path': 'training.optimizer.weight_decay', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'weight_only_checkpointing_steps': { - 'kind': 'typed', - 'path': 'training.checkpoint.weight_only_checkpointing_steps', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'weighting_scheme': { - 'kind': 'typed', - 'path': 'training.model.weighting_scheme', - 'roots': ['TrainingRunConfig'], - 'source': 'TrainingArgs' - }, - 'workload_type': { - 'convert': 'workload_type', - 'kind': 'typed', - 'none_value': 't2v', - 'path': 'pipeline.workload_type', - 'source': 'FastVideoArgs' - } -} -PIPELINE_CONFIG_TYPED_HOMES: dict[str, str] = { - 'boundary_ratio': 'pipeline.boundary_ratio', - 'bsa_cdf_threshold': 'pipeline.longcat.bsa_cdf_threshold', - 'bsa_chunk_k': 'pipeline.longcat.bsa_chunk_k', - 'bsa_chunk_q': 'pipeline.longcat.bsa_chunk_q', - 'bsa_sparsity': 'pipeline.longcat.bsa_sparsity', - 'disable_autocast': 'engine.disable_autocast', - 'dit_precision': 'engine.precision.dit', - 'dmd_denoising_steps': 'pipeline.dmd_denoising_steps', - 'embedded_cfg_scale': 'pipeline.embedded_cfg_scale', - 'enable_bsa': 'pipeline.longcat.enable_bsa', - 'flow_shift': 'pipeline.flow_shift', - 'image_encoder_precision': 'engine.precision.image_encoder', - 'model_path': 'model_path', - 'pipeline_config_path': 'pipeline.components.pipeline_config_path', - 'text_encoder_precisions': 'engine.precision.text_encoders', - 'vae_decode_precision': 'engine.precision.vae_decode', - 'vae_precision': 'engine.precision.vae', - 'vae_sp': 'pipeline.vae_sp', - 'vae_tiling': 'pipeline.vae_tiling' -} -# END GENERATED FLAT_TO_TYPED - - -def _root_name(resolved: Any) -> str: - return object.__getattribute__(resolved, "_struct").config_class.__name__ - - -def _input_mapping(resolved: Any, path: str) -> dict[str, Any]: - """Plain copy of a dict-valued field such as ``pipeline.experimental``; empty when the root lacks it.""" - present, node = _lookup(object.__getattribute__(resolved, "_struct"), path) - return _to_plain(node) if present and isinstance(node, dict) else {} - - -def generic_refine_aliases(preset_overrides: Mapping[str, Any], experimental: Mapping[str, Any]) -> dict[str, Any]: - """The ``refine_*`` values that ``FastVideoArgs`` received for these inputs, by generic key. - - ``preset_overrides.refine.enabled`` sets ``refine_enabled``; top-level ``refine_*`` keys of - ``preset_overrides``, then of ``experimental``, set their own names. A missing key is absent from the result. - """ - values: dict[str, Any] = {} - refine = preset_overrides.get("refine") - if isinstance(refine, Mapping) and "enabled" in refine: - values["refine_enabled"] = refine["enabled"] - for source in (preset_overrides, experimental): - for name in GENERIC_REFINE_PATHS: - if name in source: - values[name] = source[name] - return values - - -def resolved_generic_refine_aliases(resolved: Any) -> dict[str, Any]: - """:func:`generic_refine_aliases` for the inputs of a resolved config.""" - return generic_refine_aliases(_input_mapping(resolved, "pipeline.preset_overrides"), - _input_mapping(resolved, "pipeline.experimental")) - - -def initial_runtime_state(resolved: Any) -> dict[str, Any]: - """Runtime state of a freshly resolved config, with the ``FastVideoArgs`` defaults. - - ``ray_runtime_env`` has no typed field; ``pipeline.experimental.ray_runtime_env`` supplies it. - """ - return { - "model_paths": {}, - "model_loaded": { - "transformer": True, - "vae": True, - "upsampler": True, - }, - "ray_placement_group": None, - "ray_runtime_env": deepcopy(_input_mapping(resolved, "pipeline.experimental").get("ray_runtime_env")), - } - - -def typed_path_of_flat_name(name: str) -> str | None: - """Typed path that holds the value of a flat name, or ``None`` when the name has no typed field.""" - entry = FLAT_TO_TYPED.get(name) - if entry is not None and entry["kind"] == "typed": - return entry["path"] - return GENERIC_REFINE_PATHS.get(name) - - -def _convert(value: Any, convert: str | None) -> Any: - """Return a typed value in the flat format that ``FastVideoArgs`` or ``TrainingArgs`` used.""" - if value is None or convert is None: - return value - if convert == "workload_type": - from fastvideo.api.schema import WorkloadType - - return WorkloadType(value) - if convert == "execution_mode": - from fastvideo.api.schema import ExecutionMode - - return ExecutionMode(value) - if convert == "comma_string": - return ",".join(str(item) for item in value) - if convert == "string": - return str(value) - raise ValueError(f"unknown flat format {convert!r}") - - -def _derive(resolved: Any, entry: dict[str, Any]) -> Any: - """Value of a ``derived`` entry, computed from its typed source path.""" - struct = object.__getattribute__(resolved, "_struct") - if entry["derive"] == "torch_compile_kwargs": - from fastvideo.api.compat import _compile_config_to_torch_kwargs - - return _compile_config_to_torch_kwargs(_to_config(_lookup(struct, "engine.compile")[1])) - if entry["derive"] == "transformer_quant": - present, name = _lookup(struct, entry["path"]) - if not present or name is None: - return None - from fastvideo.layers.quantization import get_quantization_config - - return get_quantization_config(name)() - raise ValueError(f"unknown derived flat value {entry['derive']!r}") - - -def _flat_value(resolved: Any, name: str, entry: dict[str, Any]) -> Any: - """Value of one flat name; raises ``AttributeError`` when the name has no value on this root.""" - root = _root_name(resolved) - roots = entry.get("roots") - if roots is not None and root not in roots: - if "other_roots_value" in entry: - return deepcopy(entry["other_roots_value"]) - raise AttributeError(f"{root} has no field {name!r}; it exists on {', '.join(roots)}") - kind = entry["kind"] - if kind == "typed": - # The table names only paths of the root, so a path that is not present runs through an optional section - # that is None, such as engine.quantization; its value is None. - _, node = _lookup(object.__getattribute__(resolved, "_struct"), entry["path"]) - value = _to_config(node) if isinstance(node, _Struct) else _to_plain(node) - if value is None: - if root in _COMMAND_LINE_ROOTS and "cli_none_value" in entry: - value = deepcopy(entry["cli_none_value"]) - else: - value = deepcopy(entry.get("none_value")) - return _convert(value, entry.get("convert")) - if kind == "pipeline_config": - return resolved.pipeline_config - if kind == "property": - return getattr(resolved, entry["path"]) - if kind == "derived": - return _derive(resolved, entry) - if kind == "removed": - if entry.get("fallback") == "experimental": - return deepcopy(_input_mapping(resolved, "pipeline.experimental").get(name)) - if entry.get("fallback") == "generic_refine_alias": - return resolved_generic_refine_aliases(resolved).get(name) - raise AttributeError(f"{root} has no field {name!r}: {entry.get('note', 'removed')}") - raise AttributeError(f"{root} has no field {name!r}") - - -def read_flat_name(resolved: Any, name: str) -> Any: - """Value of the ``FastVideoArgs`` / ``TrainingArgs`` attribute ``name`` for a resolved config. - - Runtime-state names return the shared mutable state. Every other value is computed once per config object and - returned again on later reads. An unknown name raises ``AttributeError``, so ``getattr`` defaults still apply. - """ - if name in RUNTIME_STATE_NAMES: - return object.__getattribute__(resolved, "_runtime_state")[name] - entry = FLAT_TO_TYPED.get(name) - if entry is None: - raise AttributeError(f"{_root_name(resolved)} has no field {name!r}") - cache = object.__getattribute__(resolved, "_flat_values") - if name not in cache: - cache[name] = _flat_value(resolved, name, entry) - return cache[name] - - -def sync_pipeline_config_mirrors(resolved: Any) -> None: - """Copy the typed values of the latest override onto the ``PipelineConfig`` attributes that mirror them. - - Readers of a mirror attribute, such as ``pipeline_config.dmd_denoising_steps``, then see an override of its - typed path, as they did when ``FastVideoArgs.override`` wrote the attribute directly. ``None`` leaves the - attribute unchanged, as the flat keyword path did. - """ - pipeline_config = resolved.pipeline_config - override_log = object.__getattribute__(resolved, "_override_log") - if pipeline_config is None or not override_log: - return - attributes = {path: attribute for attribute, path in PIPELINE_CONFIG_TYPED_HOMES.items()} - _, values = override_log[-1] - for path, value in values.items(): - attribute = attributes.get(path) - if attribute is None or value is None or not hasattr(pipeline_config, attribute): - continue - mirrored = tuple(value) if attribute == "text_encoder_precisions" else deepcopy(value) - object.__setattr__(pipeline_config, attribute, mirrored) - - -__all__ = [ - "FLAT_TO_TYPED", - "GENERIC_REFINE_PATHS", - "PIPELINE_CONFIG_TYPED_HOMES", - "RUNTIME_STATE_NAMES", - "generic_refine_aliases", - "initial_runtime_state", - "read_flat_name", - "resolved_generic_refine_aliases", - "sync_pipeline_config_mirrors", - "typed_path_of_flat_name", -] diff --git a/fastvideo/api/inference_resolution.py b/fastvideo/api/inference_resolution.py index e1cda9454..d9cc44206 100644 --- a/fastvideo/api/inference_resolution.py +++ b/fastvideo/api/inference_resolution.py @@ -9,15 +9,13 @@ The steps run in this order. A fill step sets a field only while it is ``None``, precedence over a later one: user input, then environment variables, then model defaults. 1. Environment variables fill typed fields. -2. Model defaults from the model's ``PipelineConfig`` fill the typed fields that are still unset. -3. The flat keys under ``pipeline.preset_overrides`` and ``pipeline.experimental`` set the typed fields of their - names; they win over the typed input, as they do when the ``PipelineConfig`` is built. +2. Model defaults from the model's ``PipelineConfig`` fill the typed fields of ``PIPELINE_CONFIG_MIRRORS`` that are + still unset. +3. ``pipeline.preset_overrides.refine`` sets the LTX-2 refine fields. 4. Derived values replace placeholders and load the files that a path names. 5. Validation steps raise on inconsistent values and decide nothing. ``fastvideo.api.training_schema`` resolves the training and preprocessing roots with the same steps plus their own. -``FastVideoArgs.__post_init__`` and ``check_fastvideo_args`` still apply these rules to a ``FastVideoArgs`` that is -built directly. """ from __future__ import annotations @@ -26,8 +24,7 @@ import math from collections.abc import Callable, Mapping from copy import deepcopy from dataclasses import fields, is_dataclass -from enum import Enum -from typing import Any, get_args +from typing import Any import fastvideo.envs as envs from fastvideo.api.parser import parse_config @@ -76,52 +73,70 @@ def fill_vae_parallel_from_env(view: ResolutionView) -> dict[str, Any]: return values -def _pipeline_config_source(config: GeneratorConfig) -> Any: - """The ``pipeline_config`` keyword that the flat keywords of ``config`` carry: a JSON path, a dict, or an object. +# Typed path -> the ``PipelineConfig`` attribute that mirrors it. The model's ``PipelineConfig`` subclasses declare +# their defaults for these settings as attributes: the defaults step fills an unset typed field from its attribute, +# and materialization writes the resolved typed value back to the attribute. Runtime code reads the typed path. +PIPELINE_CONFIG_MIRRORS: dict[str, str] = { + "model_path": "model_path", + "pipeline.components.pipeline_config_path": "pipeline_config_path", + "engine.disable_autocast": "disable_autocast", + "engine.precision.dit": "dit_precision", + "engine.precision.vae": "vae_precision", + "engine.precision.vae_decode": "vae_decode_precision", + "engine.precision.image_encoder": "image_encoder_precision", + "engine.precision.text_encoders": "text_encoder_precisions", + "pipeline.flow_shift": "flow_shift", + "pipeline.embedded_cfg_scale": "embedded_cfg_scale", + "pipeline.dmd_denoising_steps": "dmd_denoising_steps", + "pipeline.boundary_ratio": "boundary_ratio", + "pipeline.vae_tiling": "vae_tiling", + "pipeline.vae_sp": "vae_sp", + "pipeline.longcat.enable_bsa": "enable_bsa", + "pipeline.longcat.bsa_sparsity": "bsa_sparsity", + "pipeline.longcat.bsa_cdf_threshold": "bsa_cdf_threshold", + "pipeline.longcat.bsa_chunk_q": "bsa_chunk_q", + "pipeline.longcat.bsa_chunk_k": "bsa_chunk_k", +} +# Mirrored paths that the defaults step leaves unset: an LTX-2 tile size can turn ``pipeline.vae_tiling`` on before +# :func:`vae_tiling_default_step` fills it from the model default. +_FILLED_AFTER_DERIVATION = frozenset({"pipeline.vae_tiling"}) - ``pipeline.experimental`` wins over ``pipeline.preset_overrides``, which wins over - ``pipeline.components.pipeline_config_path``. + +def _pipeline_config_source(config: GeneratorConfig) -> Any: + """The source that the model's ``PipelineConfig`` is built from: a JSON path, a mapping, or a ``PipelineConfig``. + + ``pipeline.experimental.pipeline_config`` wins over ``pipeline.components.pipeline_config_path``. """ - source = config.pipeline.components.pipeline_config_path - for overrides in (config.pipeline.preset_overrides, config.pipeline.experimental): - if overrides.get("pipeline_config") is not None: - source = overrides["pipeline_config"] - return source + source = config.pipeline.experimental.get("pipeline_config") + return config.pipeline.components.pipeline_config_path if source is None else source def build_model_pipeline_config(config: GeneratorConfig) -> Any: """Build the model's ``PipelineConfig`` before any typed value is applied. - It is the registry class for ``model_path``, updated from the ``pipeline_config`` source of - :func:`_pipeline_config_source`. The defaults step reads it, and materialization then applies the resolved values - to the same instance. + It is the registry class for ``model_path``, updated from the source of :func:`_pipeline_config_source`. The + defaults step reads it, and materialization then applies the resolved values to the same instance. """ from fastvideo.configs.pipelines.base import PipelineConfig - source = _pipeline_config_source(config) - kwargs: dict[str, Any] = {"model_path": config.model_path} - if source is not None: - kwargs["pipeline_config"] = deepcopy(source) - return PipelineConfig.from_kwargs(kwargs) + return PipelineConfig.from_source(config.model_path, deepcopy(_pipeline_config_source(config))) def pipeline_config_defaults_step(config: GeneratorConfig, defaults: Any = None) -> ResolutionStep: """Build the step that fills unset typed fields with the values of the model's ``PipelineConfig``. ``defaults`` is the instance from :func:`build_model_pipeline_config`; it is built from ``config`` when it is - not given. A typed field is filled when its flat name is an attribute of that ``PipelineConfig``, its value is - ``None``, and the attribute is not ``None``. The step's source name carries the ``PipelineConfig`` class name. + not given. A typed field of ``PIPELINE_CONFIG_MIRRORS`` is filled when its value is ``None`` and its attribute on + that ``PipelineConfig`` is not ``None``. The step's source name carries the ``PipelineConfig`` class name. """ - from fastvideo.api.compat import _FLAT_NAME_FIELDS - if defaults is None: defaults = build_model_pipeline_config(config) def fill_pipeline_config_defaults(view: ResolutionView) -> dict[str, Any]: values: dict[str, Any] = {} - for flat_name, (dotted_path, _) in _FLAT_NAME_FIELDS.items(): - default = getattr(defaults, flat_name, None) - if default is not None and view.get(dotted_path) is None: + for dotted_path, attribute in PIPELINE_CONFIG_MIRRORS.items(): + default = getattr(defaults, attribute, None) + if dotted_path not in _FILLED_AFTER_DERIVATION and default is not None and view.get(dotted_path) is None: values[dotted_path] = deepcopy(default) return values @@ -177,57 +192,14 @@ def copy_refine_preset_overrides(view: ResolutionView) -> dict[str, Any]: The keys are the refine preset and stage override fields (``enabled``, ``add_noise``, ``num_inference_steps``, ``guidance_scale``, ``image_crf``, ``video_position_offset_sec``); a ``None`` value leaves its field unchanged. """ - from fastvideo.api.compat import _LTX2_REFINE_FLAT_KEYS + from fastvideo.pipelines.basic.ltx2.stage_overrides import (refine_preset_override_fields, + refine_stage_override_fields) refine = view.get_plain("pipeline.preset_overrides").get("refine") if not isinstance(refine, Mapping): return {} - return { - f"pipeline.ltx2.refine.{key}": refine[key] - for key in sorted(_LTX2_REFINE_FLAT_KEYS) if refine.get(key) is not None - } - - -def _flat_value_for_field(annotation: Any, value: Any) -> Any: - """A flat keyword value in the type of its typed field: a string becomes the member of an enum field.""" - enum_types = [arg for arg in (annotation, *get_args(annotation)) if isinstance(arg, type) and issubclass(arg, Enum)] - if enum_types and isinstance(value, str) and not isinstance(value, enum_types[0]): - return enum_types[0](value) - return deepcopy(value) - - -def route_flat_override_keys(view: ResolutionView) -> dict[str, Any]: - """The flat keys under ``pipeline.preset_overrides`` and then ``pipeline.experimental`` set their typed fields. - - A key that is the flat name of a typed field sets that field; ``dit_config.`` and ``vae_config.`` set - ``pipeline.dit`` and ``pipeline.vae`` entries; a string ``pipeline_config`` sets - ``pipeline.components.pipeline_config_path``. A generic ``refine_*`` key then sets its LTX-2 refine field, so it - wins over the ``ltx2_refine_*`` key. ``None`` values and keys without a typed field change nothing. - """ - from fastvideo.api.compat import _COMPONENT_OVERRIDE_PREFIXES, _FLAT_NAME_FIELDS - from fastvideo.api.flat_name_fallback import GENERIC_REFINE_PATHS, generic_refine_aliases - - preset_overrides = view.get_plain("pipeline.preset_overrides") - experimental = view.get_plain("pipeline.experimental") - flat_inputs = {key: value for key, value in preset_overrides.items() if key != "refine"} - flat_inputs.update(experimental) - values: dict[str, Any] = {} - for key, value in flat_inputs.items(): - if value is None: - continue - prefixes = [prefix for prefix in _COMPONENT_OVERRIDE_PREFIXES if key.startswith(prefix)] - if prefixes: - values[f"pipeline.{_COMPONENT_OVERRIDE_PREFIXES[prefixes[0]]}.{key[len(prefixes[0]):]}"] = value - elif key == "pipeline_config": - if isinstance(value, str): - values["pipeline.components.pipeline_config_path"] = value - elif key in _FLAT_NAME_FIELDS: - dotted_path, annotation = _FLAT_NAME_FIELDS[key] - values[dotted_path] = _flat_value_for_field(annotation, value) - for name, value in generic_refine_aliases(preset_overrides, experimental).items(): - if value is not None: - values[GENERIC_REFINE_PATHS[name]] = value - return values + keys = refine_preset_override_fields() | refine_stage_override_fields() + return {f"pipeline.ltx2.refine.{key}": refine[key] for key in sorted(keys) if refine.get(key) is not None} def load_moba_config(view: ResolutionView) -> dict[str, Any]: @@ -263,6 +235,32 @@ def validate_lora_strength(view: ResolutionView) -> dict[str, Any]: return {} +# Typed fields that no runtime code reads. Resolution rejects a value at one of them, so the setting is not dropped. +UNSUPPORTED_PATHS = ("pipeline.preset", "pipeline.preset_version", "pipeline.components.vae_weights") + + +def validate_unsupported_fields(view: ResolutionView) -> dict[str, Any]: + """The fields of ``UNSUPPORTED_PATHS`` must be unset.""" + unsupported = [path for path in UNSUPPORTED_PATHS if view.get(path) is not None] + if unsupported: + raise NotImplementedError(f"resolution does not support {', '.join(unsupported)}; leave these fields unset") + return {} + + +def validate_experimental_keys(view: ResolutionView) -> dict[str, Any]: + """A ``pipeline.experimental`` key must not name a ``PipelineConfig`` attribute that has a typed path. + + Materialization writes those attributes from their typed paths (``PIPELINE_CONFIG_MIRRORS``), so the key is set at + the typed path instead. + """ + typed_paths = {attribute: path for path, attribute in PIPELINE_CONFIG_MIRRORS.items()} + misplaced = sorted(set(view.get("pipeline.experimental")) & set(typed_paths)) + if misplaced: + moves = ", ".join(f"pipeline.experimental.{key} -> {typed_paths[key]}" for key in misplaced) + raise ValueError(f"these settings have typed config paths; set them there: {moves}") + return {} + + def validate_attention_backend(view: ResolutionView) -> dict[str, Any]: """A set ``engine.attention.backend`` must name a supported backend, so a typo fails before any model loads.""" backend = view.get("engine.attention.backend") @@ -350,10 +348,10 @@ ENVIRONMENT_STEPS: tuple[ResolutionStep, ...] = ( fill_regional_compile_from_env, fill_vae_parallel_from_env, ) -# Steps between the model defaults and the derived values: inputs written under flat keyword names. -FLAT_INPUT_STEPS: tuple[ResolutionStep, ...] = (copy_refine_preset_overrides, route_flat_override_keys) # Steps that check the values decided so far against each other. VALIDATION_STEPS: tuple[ResolutionStep, ...] = ( + validate_unsupported_fields, + validate_experimental_keys, validate_lora_strength, validate_attention_backend, validate_vae_parallel_decode_strategy, @@ -370,7 +368,7 @@ def generator_resolution_steps( ) -> tuple[ResolutionStep, ...]: """The resolution steps of any generator root, in the order that they run. - ``before_placeholders`` runs after the flat inputs and before ``derive_parallel_sizes``, for checks that need the + ``before_placeholders`` runs after the refine copy and before ``derive_parallel_sizes``, for checks that need the -1 placeholders; ``after`` runs last. ``validate_parallel_sizes`` checks the sizes before ``derive_num_gpus_from_parallel_sizes`` raises ``num_gpus``. """ @@ -379,7 +377,7 @@ def generator_resolution_steps( return ( *ENVIRONMENT_STEPS, pipeline_config_defaults_step(config, defaults), - *FLAT_INPUT_STEPS, + copy_refine_preset_overrides, *before_placeholders, derive_parallel_sizes, derive_vae_tiling_from_ltx2_tile_sizes, @@ -398,61 +396,72 @@ def inference_resolution_steps(config: GeneratorConfig, defaults: Any = None) -> return generator_resolution_steps(config, defaults) -def _apply_ltx2_vae_overrides(pipeline_config: Any, flat: Mapping[str, Any]) -> None: - """Apply the LTX-2 VAE tiling keywords to ``pipeline_config``, as ``FastVideoArgs`` did after construction. - - ``ltx2_vae_tiling`` sets ``vae_tiling``; otherwise any tile size turns it on. Each tile size is written onto - ``vae_config`` when the VAE config has that attribute. - """ - tile_sizes = { - "ltx2_spatial_tile_size_in_pixels": flat.get("ltx2_vae_spatial_tile_size_in_pixels"), - "ltx2_spatial_tile_overlap_in_pixels": flat.get("ltx2_vae_spatial_tile_overlap_in_pixels"), - "ltx2_temporal_tile_size_in_frames": flat.get("ltx2_vae_temporal_tile_size_in_frames"), - "ltx2_temporal_tile_overlap_in_frames": flat.get("ltx2_vae_temporal_tile_overlap_in_frames"), - } - if flat.get("ltx2_vae_tiling") is not None and hasattr(pipeline_config, "vae_tiling"): - pipeline_config.vae_tiling = flat["ltx2_vae_tiling"] - elif any(value is not None for value in tile_sizes.values()) and hasattr(pipeline_config, "vae_tiling"): - pipeline_config.vae_tiling = True - vae_config = pipeline_config.vae_config - for attribute, value in tile_sizes.items(): - if value is not None and hasattr(vae_config, attribute): - setattr(vae_config, attribute, value) +# LTX-2 VAE tile size path -> the ``vae_config`` attribute that the LTX-2 VAE reads. +_LTX2_VAE_TILE_ATTRIBUTES = { + "pipeline.ltx2.vae_spatial_tile_size_in_pixels": "ltx2_spatial_tile_size_in_pixels", + "pipeline.ltx2.vae_spatial_tile_overlap_in_pixels": "ltx2_spatial_tile_overlap_in_pixels", + "pipeline.ltx2.vae_temporal_tile_size_in_frames": "ltx2_temporal_tile_size_in_frames", + "pipeline.ltx2.vae_temporal_tile_overlap_in_frames": "ltx2_temporal_tile_overlap_in_frames", +} -def _apply_transformer_quant(pipeline_config: Any, transformer_quant: Any) -> None: - """Pin a transformer quantization config on ``dit_config.quant_config`` unless one is already set there. +def _config_value(config: GeneratorConfig, path: str) -> Any: + """Value at a dotted field path of a typed config; ``None`` through an optional section that is ``None``.""" + node: Any = config + for part in path.split("."): + if node is None: + return None + node = getattr(node, part) + return node - A registry name such as ``nvfp4_qat_train`` becomes its ``QuantizationConfig`` instance first. + +def _set_present_attributes(target: Any, values: Mapping[str, Any]) -> None: + """Set each value that is not ``None`` on ``target`` when ``target`` has an attribute of that name.""" + for name, value in values.items(): + if value is not None and hasattr(target, name): + setattr(target, name, value) + + +def _apply_transformer_quant(pipeline_config: Any, transformer_quant: str | None) -> None: + """Pin the quantization config that ``transformer_quant`` names on ``dit_config.quant_config`` unless one is set. + + A registry name such as ``nvfp4_qat_train`` becomes its ``QuantizationConfig`` instance. """ dit_config = getattr(pipeline_config, "dit_config", None) if transformer_quant is None or dit_config is None: return - if isinstance(transformer_quant, str): - from fastvideo.layers.quantization import get_quantization_config - transformer_quant = get_quantization_config(transformer_quant)() + from fastvideo.layers.quantization import get_quantization_config + if getattr(dit_config, "quant_config", None) is None: - dit_config.quant_config = transformer_quant + dit_config.quant_config = get_quantization_config(transformer_quant)() def materialize_pipeline_config(resolved: ResolvedGeneratorConfig, pipeline_config: Any) -> Any: """Apply the resolved values to the model's ``PipelineConfig``, validate it, and freeze it. - ``pipeline_config`` is the instance from :func:`build_model_pipeline_config`. The flat keywords of - :func:`fastvideo.api.compat.generator_kwargs` update it with the rules of ``PipelineConfig.update_config_from_dict`` - (``dit_config.`` and ``vae_config.`` included). The keywords that it leaves are the ones that apply the - LTX-2 VAE tiling and the transformer quantization. A preprocessing run loads the VAE encoder. + ``pipeline_config`` is the instance from :func:`build_model_pipeline_config`. In order, materialization sets the + ``pipeline.experimental`` keys that are ``PipelineConfig`` attributes (model-only fields), the attributes of + ``PIPELINE_CONFIG_MIRRORS`` from their typed values, and the ``pipeline.vae`` and ``pipeline.dit`` entries on + ``vae_config`` and ``dit_config``; a ``None`` value leaves its attribute unchanged. It then writes the LTX-2 VAE + tile sizes onto ``vae_config``, pins the ``engine.quantization.transformer_quant`` config on ``dit_config``, runs + ``check_pipeline_config``, and loads the VAE encoder for a preprocessing run. """ - from fastvideo.api.compat import generator_kwargs - - flat = generator_kwargs(resolved) - source = flat.get("pipeline_config") - if isinstance(source, str): - flat["pipeline_config_path"] = source - flat["model_path"] = resolved.model_path - pipeline_config.update_config_from_dict(flat) - _apply_ltx2_vae_overrides(pipeline_config, flat) - _apply_transformer_quant(pipeline_config, flat.get("transformer_quant")) + config = resolved.to_config() + _set_present_attributes(pipeline_config, { + key: value + for key, value in config.pipeline.experimental.items() if key != "pipeline_config" + }) + mirrored = {attribute: _config_value(config, path) for path, attribute in PIPELINE_CONFIG_MIRRORS.items()} + if mirrored["text_encoder_precisions"] is not None: + mirrored["text_encoder_precisions"] = tuple(mirrored["text_encoder_precisions"]) + _set_present_attributes(pipeline_config, mirrored) + _set_present_attributes(pipeline_config.vae_config, config.pipeline.vae) + _set_present_attributes(pipeline_config.dit_config, config.pipeline.dit) + _set_present_attributes(pipeline_config.vae_config, { + attribute: _config_value(config, path) + for path, attribute in _LTX2_VAE_TILE_ATTRIBUTES.items() + }) + _apply_transformer_quant(pipeline_config, _config_value(config, "engine.quantization.transformer_quant")) pipeline_config.check_pipeline_config() if resolved.mode == ExecutionMode.PREPROCESS and not pipeline_config.vae_config.load_encoder: pipeline_config.vae_config.load_encoder = True @@ -526,7 +535,7 @@ def _non_default_fields(value: Any, default: Any) -> dict[str, Any]: __all__ = [ "torch_compile_kwargs", "ENVIRONMENT_STEPS", - "FLAT_INPUT_STEPS", + "PIPELINE_CONFIG_MIRRORS", "VALIDATION_STEPS", "build_model_pipeline_config", "copy_refine_preset_overrides", @@ -543,10 +552,11 @@ __all__ = [ "pipeline_config_defaults_step", "resolve_config", "resolve_inference_config", - "route_flat_override_keys", "validate_attention_backend", + "validate_experimental_keys", "validate_lora_strength", "validate_parallel_sizes", + "validate_unsupported_fields", "validate_vae_parallel_decode_strategy", "warn_deprecated_environment_variables", "written_fields", diff --git a/fastvideo/api/resolution.py b/fastvideo/api/resolution.py index 911bbcb3b..081233b32 100644 --- a/fastvideo/api/resolution.py +++ b/fastvideo/api/resolution.py @@ -412,12 +412,9 @@ class ResolvedGeneratorConfig(_ResolvedTree): same ``pipeline_config``. ``training_mode`` and ``inference_mode`` are read-only views of the top-level ``mode`` field. - - Code that still reads the flat ``FastVideoArgs`` attribute names reaches the values through - :mod:`fastvideo.api.flat_name_fallback`, which also holds the mutable runtime state behind those names. """ - __slots__ = ("_pipeline_config", "_runtime_state", "_flat_values") + __slots__ = ("_pipeline_config", ) def __init__( self, @@ -427,39 +424,14 @@ class ResolvedGeneratorConfig(_ResolvedTree): decisions: Sequence[Decision], override_log: Sequence[Decision], pipeline_config: Any = None, - runtime_state: dict[str, Any] | None = None, ): - """Hold the resolved tree with its ``pipeline_config`` and runtime state; new state starts at its defaults.""" - from fastvideo.api import flat_name_fallback - super().__init__(tree, raw_tree, explicit_paths, decisions, override_log) object.__setattr__(self, "_pipeline_config", pipeline_config) - object.__setattr__(self, "_flat_values", {}) - if runtime_state is None: - runtime_state = flat_name_fallback.initial_runtime_state(self) - object.__setattr__(self, "_runtime_state", runtime_state) def __reduce__(self) -> tuple[Any, ...]: state = object.__getattribute__ return type(self), (state(self, "_struct"), state(self, "_raw_tree"), state(self, "_explicit_paths"), - state(self, "_decisions"), state(self, "_override_log"), state(self, "_pipeline_config"), - state(self, "_runtime_state")) - - def __getattr__(self, name: str) -> Any: - struct = object.__getattribute__(self, "_struct") - if name in struct.fields: - return super().__getattr__(name) - from fastvideo.api import flat_name_fallback - - return flat_name_fallback.read_flat_name(self, name) - - def __setattr__(self, name: str, value: Any) -> None: - from fastvideo.api import flat_name_fallback - - if name in flat_name_fallback.RUNTIME_STATE_NAMES: - object.__getattribute__(self, "_runtime_state")[name] = value - return - super().__setattr__(name, value) + state(self, "_decisions"), state(self, "_override_log"), state(self, "_pipeline_config")) @property def pipeline_config(self) -> Any: @@ -478,16 +450,12 @@ class ResolvedGeneratorConfig(_ResolvedTree): return not self.training_mode def with_override(self, source: str, values: Mapping[str, Any]) -> ResolvedGeneratorConfig: - from fastvideo.api import flat_name_fallback - - overridden = super().with_override(source, values) - flat_name_fallback.sync_pipeline_config_mirrors(overridden) - return overridden + return super().with_override(source, values) def _replace(self, tree: _Struct, override_log: tuple[Decision, ...]) -> ResolvedGeneratorConfig: state = object.__getattribute__ return type(self)(tree, state(self, "_raw_tree"), state(self, "_explicit_paths"), state(self, "_decisions"), - override_log, state(self, "_pipeline_config"), state(self, "_runtime_state")) + override_log, state(self, "_pipeline_config")) def to_config(self) -> GeneratorConfig: """Typed copy of the resolved values as the root config class, for code that consumes the typed config.""" @@ -550,8 +518,7 @@ def resolve_generator_config( resolved = ResolvedGeneratorConfig(tree, raw_tree, frozenset(explicit_paths), decisions, ()) if materialize is None: return resolved - return ResolvedGeneratorConfig(tree, raw_tree, frozenset(explicit_paths), decisions, (), materialize(resolved), - object.__getattribute__(resolved, "_runtime_state")) + return ResolvedGeneratorConfig(tree, raw_tree, frozenset(explicit_paths), decisions, (), materialize(resolved)) def resolve_generation_request(request: GenerationRequest, steps: Sequence[ResolutionStep]) -> ResolvedRequest: diff --git a/fastvideo/api/sampling_param.py b/fastvideo/api/sampling_param.py index c96239a94..f85b56b51 100644 --- a/fastvideo/api/sampling_param.py +++ b/fastvideo/api/sampling_param.py @@ -6,7 +6,6 @@ from dataclasses import dataclass, field, fields from typing import TYPE_CHECKING, Any from fastvideo.logger import init_logger -from fastvideo.utils import StoreBoolean if TYPE_CHECKING: from fastvideo.api.schema import ContinuationState @@ -255,203 +254,6 @@ class SamplingParam: sp.__post_init__() return sp - @staticmethod - def add_cli_args(parser: Any) -> Any: - """Add CLI arguments for SamplingParam fields""" - parser.add_argument( - "--prompt", - type=str, - default=SamplingParam.prompt, - help="Text prompt for video generation", - ) - parser.add_argument( - "--negative-prompt", - type=str, - default=SamplingParam.negative_prompt, - help="Negative text prompt for video generation", - ) - parser.add_argument( - "--prompt-path", - type=str, - default=SamplingParam.prompt_path, - help="Path to a text file containing the prompt", - ) - parser.add_argument( - "--output-path", - type=str, - default=SamplingParam.output_path, - help="Path to save the generated video", - ) - parser.add_argument( - "--output-video-name", - type=str, - default=SamplingParam.output_video_name, - help="Name of the output video", - ) - parser.add_argument( - "--num-videos-per-prompt", - type=int, - default=SamplingParam.num_videos_per_prompt, - help="Number of videos to generate per prompt", - ) - parser.add_argument( - "--seed", - type=int, - default=SamplingParam.seed, - help="Random seed for generation", - ) - parser.add_argument( - "--num-frames", - type=int, - default=SamplingParam.num_frames, - help="Number of frames to generate", - ) - parser.add_argument( - "--height", - type=int, - default=SamplingParam.height, - help="Height of generated video", - ) - parser.add_argument( - "--width", - type=int, - default=SamplingParam.width, - help="Width of generated video", - ) - parser.add_argument( - "--fps", - type=int, - default=SamplingParam.fps, - help="Frames per second for saved video", - ) - parser.add_argument( - "--num-inference-steps", - type=int, - default=SamplingParam.num_inference_steps, - help="Number of denoising steps", - ) - parser.add_argument( - "--guidance-scale", - type=float, - default=SamplingParam.guidance_scale, - help="Classifier-free guidance scale", - ) - parser.add_argument( - "--cfg-normalization", - action=StoreBoolean, - default=SamplingParam.cfg_normalization, - help="Cap Z-Image CFG prediction norm to the positive-prediction norm", - ) - parser.add_argument( - "--cfg-truncation", - type=float, - default=SamplingParam.cfg_truncation, - help="Disable Z-Image CFG above this normalized-noise threshold", - ) - parser.add_argument( - "--batch-cfg", - action=StoreBoolean, - default=SamplingParam.batch_cfg, - help="Evaluate conditional and unconditional CFG branches in one batch", - ) - parser.add_argument( - "--guidance-rescale", - type=float, - default=SamplingParam.guidance_rescale, - help="Guidance rescale factor", - ) - parser.add_argument( - "--use-embedded-guidance", - action="store_true", - default=SamplingParam.use_embedded_guidance, - help="Use embedded guidance scale (FLUX-style) instead of classic CFG", - ) - parser.add_argument( - "--true-cfg-scale", - type=float, - default=SamplingParam.true_cfg_scale, - help="True CFG scale for FLUX when > 1 (requires negative prompt encoding)", - ) - parser.add_argument( - "--boundary-ratio", - type=float, - default=SamplingParam.boundary_ratio, - help="Boundary timestep ratio", - ) - parser.add_argument( - "--save-video", - action="store_true", - default=SamplingParam.save_video, - help="Whether to save the video to disk", - ) - parser.add_argument( - "--no-save-video", - action="store_false", - dest="save_video", - help="Don't save the video to disk", - ) - parser.add_argument( - "--return-frames", - action="store_true", - default=False, - help="Whether to return the raw frames", - ) - parser.add_argument( - "--image-path", - type=str, - default=SamplingParam.image_path, - help="Path to input image for image-to-video generation", - ) - parser.add_argument( - "--video-path", - type=str, - default=SamplingParam.video_path, - help="Path to input video for video-to-video generation", - ) - parser.add_argument( - "--refine-from", - type=str, - default=SamplingParam.refine_from, - help="Path to stage1 video for refinement (LongCat 480p->720p)", - ) - parser.add_argument( - "--t-thresh", - type=float, - default=SamplingParam.t_thresh, - help="Threshold for timestep scheduling in refinement (default: 0.5)", - ) - parser.add_argument( - "--spatial-refine-only", - action=StoreBoolean, - default=SamplingParam.spatial_refine_only, - help="Only perform spatial super-resolution (no temporal doubling)", - ) - parser.add_argument( - "--num-cond-frames", - type=int, - default=SamplingParam.num_cond_frames, - help="Number of conditioning frames for refinement", - ) - parser.add_argument( - "--moba-config-path", - type=str, - default=None, - help="Path to a JSON file containing V-MoBA specific configurations.", - ) - parser.add_argument( - "--return-trajectory-latents", - action="store_true", - default=SamplingParam.return_trajectory_latents, - help="Whether to return the trajectory", - ) - parser.add_argument( - "--return-trajectory-decoded", - action="store_true", - default=SamplingParam.return_trajectory_decoded, - help="Whether to return the decoded trajectory", - ) - return parser - @dataclass class CacheParams: diff --git a/fastvideo/api/schema.py b/fastvideo/api/schema.py index 1e00fe046..64fab5b76 100644 --- a/fastvideo/api/schema.py +++ b/fastvideo/api/schema.py @@ -5,14 +5,14 @@ from dataclasses import MISSING, dataclass, field from enum import Enum from typing import Any, Literal -# Field metadata key that holds a field's name in the flat keyword API: the keyword arguments of -# ``VideoGenerator.from_pretrained`` and the fields of ``FastVideoArgs``. ``fastvideo.api.compat`` converts between -# the nested config and the flat keywords through this name, so a field that declares it needs no other mapping. +# Field metadata key that holds the ``VideoGenerator.from_pretrained`` keyword that sets a field. +# ``fastvideo.api.compat.from_pretrained_kwargs_to_config`` maps each keyword of ``FROM_PRETRAINED_KWARGS`` to the +# field that declares it. FLAT_NAME = "flat_name" def flat_field(flat_name: str, default: Any = MISSING, *, default_factory: Any = MISSING) -> Any: - """Declare a dataclass field whose name in the flat keyword API is ``flat_name``.""" + """Declare a dataclass field that the ``VideoGenerator.from_pretrained`` keyword ``flat_name`` sets.""" return field(default=default, default_factory=default_factory, metadata={FLAT_NAME: flat_name}) @@ -35,11 +35,6 @@ class ExecutionMode(str, Enum): except ValueError: raise ValueError(f"Invalid mode: {value}. Must be one of: {', '.join([m.value for m in cls])}") from None - @classmethod - def choices(cls) -> list[str]: - """Get all available choices as strings for argparse.""" - return [mode.value for mode in cls] - class WorkloadType(str, Enum): """ @@ -63,11 +58,6 @@ class WorkloadType(str, Enum): raise ValueError( f"Invalid workload type: {value}. Must be one of: {', '.join([m.value for m in cls])}") from None - @classmethod - def choices(cls) -> list[str]: - """Get all available choices as strings for argparse.""" - return [workload.value for workload in cls] - @dataclass class ServerConfig: @@ -84,7 +74,7 @@ class ParallelismConfig: hsdp_replicate_dim: int = flat_field("hsdp_replicate_dim", 1) hsdp_shard_dim: int = flat_field("hsdp_shard_dim", -1) dist_timeout: int | None = flat_field("dist_timeout", None) - master_port: int | None = flat_field("master_port", None) + master_port: int | None = None """Port of the rendezvous that the executor opens for its workers. ``None`` picks an open port.""" @@ -101,7 +91,7 @@ class OffloadConfig: # overlapping set rather than the sum. Grouped here because it is the same # decision the offload knobs answer, which is how much of the model has to # be resident at once. ``None`` auto-enables on unified-memory devices. - lazy_module_load: bool | None = flat_field("lazy_module_load", None) + lazy_module_load: bool | None = None @dataclass @@ -128,31 +118,31 @@ class CompileConfig: dynamic: bool | None = None extras: dict[str, Any] = field(default_factory=dict) - text_encoder_enabled: bool | None = flat_field("enable_torch_compile_text_encoder", None) - vae_enabled: bool | None = flat_field("enable_torch_compile_vae", None) - audio_vae_enabled: bool | None = flat_field("enable_torch_compile_audio_vae", None) - regional: bool | None = flat_field("inference_torch_compile", None) + text_encoder_enabled: bool | None = None + vae_enabled: bool | None = None + audio_vae_enabled: bool | None = None + regional: bool | None = None """Regional fullgraph compile of each DiT transformer block, independent of ``enabled``. The loader applies it with fixed options and ignores the kwargs below. ``None`` falls back to ``FASTVIDEO_INFERENCE_TORCH_COMPILE``.""" - dit_kwargs: dict[str, Any] = flat_field("torch_compile_kwargs_dit", default_factory=dict) - text_encoder_kwargs: dict[str, Any] = flat_field("torch_compile_kwargs_text_encoder", default_factory=dict) - vae_kwargs: dict[str, Any] = flat_field("torch_compile_kwargs_vae", default_factory=dict) - audio_vae_kwargs: dict[str, Any] = flat_field("torch_compile_kwargs_audio_vae", default_factory=dict) + dit_kwargs: dict[str, Any] = field(default_factory=dict) + text_encoder_kwargs: dict[str, Any] = field(default_factory=dict) + vae_kwargs: dict[str, Any] = field(default_factory=dict) + audio_vae_kwargs: dict[str, Any] = field(default_factory=dict) @dataclass class AttentionConfig: - backend: str | None = flat_field("attention_backend", None) + backend: str | None = None """Default attention backend request, such as ``FLASH_ATTN`` or ``TORCH_SDPA``, applied per component at load time. ``None`` falls back to ``FASTVIDEO_ATTENTION_BACKEND``, then per-layer defaults, then automatic selection.""" - vsa_sparsity: float | None = flat_field("VSA_sparsity", None) + vsa_sparsity: float | None = None """Video sparse attention (VSA) sparsity at inference. ``None`` keeps the default of 0.0.""" - vsa_tile_size: int | None = flat_field("VSA_tile_size", None) + vsa_tile_size: int | None = None """VSA tile size in tokens, 256 or 64; 64 runs the native Triton block-sparse path. ``None`` keeps 256.""" - moba_config_path: str | None = flat_field("moba_config_path", None) + moba_config_path: str | None = None """Path to a JSON config for V-MoBA attention.""" - moba_config: dict[str, Any] | None = flat_field("moba_config", None) + moba_config: dict[str, Any] | None = None """V-MoBA attention settings. Resolution loads them from ``moba_config_path`` when that path is set.""" @@ -163,17 +153,17 @@ Precision = Literal["fp32", "fp16", "bf16"] class PrecisionConfig: """Numeric precision of each model component. ``None`` keeps the model's default.""" - dit: Precision | None = flat_field("dit_precision", None) - vae: Precision | None = flat_field("vae_precision", None) - vae_decode: Precision | None = flat_field("vae_decode_precision", None) - image_encoder: Precision | None = flat_field("image_encoder_precision", None) - text_encoders: list[Precision] | None = flat_field("text_encoder_precisions", None) + dit: Precision | None = None + vae: Precision | None = None + vae_decode: Precision | None = None + image_encoder: Precision | None = None + text_encoders: list[Precision] | None = None """One precision per text encoder, in the model's text encoder order.""" @dataclass class QuantizationConfig: - text_encoder_quant: str | None = flat_field("override_text_encoder_quant", None) + text_encoder_quant: str | None = None transformer_quant: str | None = None @@ -194,21 +184,21 @@ class EngineConfig: @dataclass class ComponentConfig: - config_root: str | None = flat_field("config_model_path", None) - pipeline_config_path: str | None = flat_field("pipeline_config", None) - text_encoder_weights: str | None = flat_field("override_text_encoder_safetensors", None) - transformer_weights: str | None = flat_field("init_weights_from_safetensors", None) - transformer_2_weights: str | None = flat_field("init_weights_from_safetensors_2", None) + config_root: str | None = None + pipeline_config_path: str | None = None + text_encoder_weights: str | None = None + transformer_weights: str | None = None + transformer_2_weights: str | None = None vae_weights: str | None = None - upsampler_weights: str | None = flat_field("ltx2_refine_upsampler_path", None) + upsampler_weights: str | None = None lora_path: str | None = flat_field("lora_path", None) - lora_nickname: str = flat_field("lora_nickname", "default") + lora_nickname: str = "default" lora_strength: float = flat_field("lora_strength", 1.0) - lora_target_modules: list[str] | None = flat_field("lora_target_modules", None) + lora_target_modules: list[str] | None = None """Module name substrings that restrict LoRA injection, such as ``["q_proj", "v_proj"]``. ``None`` adapts the default modules.""" - override_pipeline_cls_name: str | None = flat_field("override_pipeline_cls_name", None) - override_transformer_cls_name: str | None = flat_field("override_transformer_cls_name", None) + override_pipeline_cls_name: str | None = None + override_transformer_cls_name: str | None = None @dataclass @@ -221,41 +211,41 @@ class LTX2RefineOptions: ``num_inference_steps`` that are still ``None`` then become ``False``, ``True``, 1.0, and 3. """ - enabled: bool | None = flat_field("ltx2_refine_enabled", None) + enabled: bool | None = None """Run the stage-2 spatial refine. ``None`` is ``False``.""" - num_inference_steps: int | None = flat_field("ltx2_refine_num_inference_steps", None) + num_inference_steps: int | None = None """Stage-2 denoising steps, 2 or 3. ``None`` is 3.""" - guidance_scale: float | None = flat_field("ltx2_refine_guidance_scale", None) + guidance_scale: float | None = None """Stage-2 guidance scale. ``None`` is 1.0.""" - add_noise: bool | None = flat_field("ltx2_refine_add_noise", None) + add_noise: bool | None = None """Add noise to the upsampled latents before stage 2. ``None`` is ``True``.""" image_crf: int | None = None """Stage-2 image conditioning CRF from ``preset_overrides.refine``. Requests set it per call.""" video_position_offset_sec: float | None = None """Stage-2 video position offset from ``preset_overrides.refine``. Requests set it per call.""" - transformer_path: str | None = flat_field("ltx2_refine_transformer_path", None) - lora_path: str | None = flat_field("ltx2_refine_lora_path", None) + transformer_path: str | None = None + lora_path: str | None = None """LoRA applied to the refine transformer only. ``None`` uses the checkpoint's default (``fastvideo_refine_lora_path`` in ``model_index.json``); an empty string disables the refine LoRA.""" - noise_path: str | None = flat_field("ltx2_refine_noise_path", None) - audio_noise_path: str | None = flat_field("ltx2_refine_audio_noise_path", None) + noise_path: str | None = None + audio_noise_path: str | None = None @dataclass class LTX2Options: """LTX-2 settings. ``None`` keeps the model's default.""" - vae_spatial_tile_size_in_pixels: int | None = flat_field("ltx2_vae_spatial_tile_size_in_pixels", None) - vae_spatial_tile_overlap_in_pixels: int | None = flat_field("ltx2_vae_spatial_tile_overlap_in_pixels", None) - vae_temporal_tile_size_in_frames: int | None = flat_field("ltx2_vae_temporal_tile_size_in_frames", None) - vae_temporal_tile_overlap_in_frames: int | None = flat_field("ltx2_vae_temporal_tile_overlap_in_frames", None) - initial_latent_path: str | None = flat_field("ltx2_initial_latent_path", None) + vae_spatial_tile_size_in_pixels: int | None = None + vae_spatial_tile_overlap_in_pixels: int | None = None + vae_temporal_tile_size_in_frames: int | None = None + vae_temporal_tile_overlap_in_frames: int | None = None + initial_latent_path: str | None = None """Path to load or save a precomputed initial video latent.""" - audio_latent_path: str | None = flat_field("ltx2_audio_latent_path", None) + audio_latent_path: str | None = None """Path to load or save a precomputed initial audio latent.""" - legacy_native_noise_order: bool | None = flat_field("ltx2_legacy_native_noise_order", None) + legacy_native_noise_order: bool | None = None """Draw latent noise in the legacy native order, which earlier SSIM references use.""" - use_distilled_sigmas: bool | None = flat_field("ltx2_use_distilled_sigmas", None) + use_distilled_sigmas: bool | None = None """Use the distilled sigma schedule when the checkpoint provides one.""" refine: LTX2RefineOptions = field(default_factory=LTX2RefineOptions) @@ -264,23 +254,22 @@ class LTX2Options: class MiniMaxH3Options: """MiniMax-H3 settings. ``None`` keeps the model's default.""" - sequential_load: bool | None = flat_field("h3_sequential_load", None) + sequential_load: bool | None = None """Encode with Qwen3-VL, release that encoder, then load the DiT and VAEs. ``None`` enables it on unified-memory devices only.""" - video_decode_backend: Literal["h3-vae", "taeh3"] | None = flat_field("video_decode_backend", None) + video_decode_backend: Literal["h3-vae", "taeh3"] | None = None """``h3-vae`` is the full VAE; ``taeh3`` is a fast approximate preview decoder.""" - taeh3_checkpoint: str | None = flat_field("taeh3_checkpoint", None) + taeh3_checkpoint: str | None = None """Local ``taeh3.safetensors`` path. ``None`` downloads the pinned upstream weights.""" - taeh3_chunk_size: int | None = flat_field("taeh3_chunk_size", None) + taeh3_chunk_size: int | None = None """TAEH3 latent frames per execution chunk.""" - vae_parallel_decode: bool | None = flat_field("vae_parallel_decode", None) + vae_parallel_decode: bool | None = None """Spread VAE decode chunks across the sequence-parallel ranks. ``None`` falls back to ``FASTVIDEO_VAE_PARALLEL_DECODE``.""" - vae_parallel_encode: bool | None = flat_field("vae_parallel_encode", None) + vae_parallel_encode: bool | None = None """Spread reference-video VAE encode clips across the sequence-parallel ranks. ``None`` falls back to ``FASTVIDEO_VAE_PARALLEL_ENCODE``.""" - vae_parallel_decode_strategy: Literal["gather", "all_gather"] | None = flat_field( - "vae_parallel_decode_strategy", None) + vae_parallel_decode_strategy: Literal["gather", "all_gather"] | None = None """Collective that moves decoded chunks. ``None`` falls back to ``FASTVIDEO_VAE_PARALLEL_DECODE_STRATEGY``, then ``gather``.""" @@ -289,32 +278,32 @@ class MiniMaxH3Options: class LongCatOptions: """LongCat block sparse attention (BSA) settings. ``None`` keeps the model's default.""" - enable_bsa: bool | None = flat_field("enable_bsa", None) - bsa_sparsity: float | None = flat_field("bsa_sparsity", None) - bsa_cdf_threshold: float | None = flat_field("bsa_cdf_threshold", None) - bsa_chunk_q: list[int] | None = flat_field("bsa_chunk_q", None) + enable_bsa: bool | None = None + bsa_sparsity: float | None = None + bsa_cdf_threshold: float | None = None + bsa_chunk_q: list[int] | None = None """Query chunk shape as ``[T, H, W]``.""" - bsa_chunk_k: list[int] | None = flat_field("bsa_chunk_k", None) + bsa_chunk_k: list[int] | None = None """Key chunk shape as ``[T, H, W]``.""" @dataclass class PipelineSelection: - workload_type: WorkloadType | None = flat_field("workload_type", None) + workload_type: WorkloadType | None = None preset: str | None = None preset_version: int | None = None components: ComponentConfig = field(default_factory=ComponentConfig) - vae_tiling: bool | None = flat_field("ltx2_vae_tiling", None) + vae_tiling: bool | None = None """Tile-based VAE decode. ``None`` keeps the model's default.""" - vae_sp: bool | None = flat_field("vae_sp", None) + vae_sp: bool | None = None """VAE spatial parallelism across ranks; requires ``vae_tiling``. ``None`` keeps the model's default.""" - flow_shift: float | None = flat_field("flow_shift", None) + flow_shift: float | None = None """Flow-matching scheduler shift. ``None`` keeps the model's default.""" - embedded_cfg_scale: float | None = flat_field("embedded_cfg_scale", None) + embedded_cfg_scale: float | None = None """Guidance scale that guidance-distilled models take as a DiT input. ``None`` keeps the model's default.""" - dmd_denoising_steps: list[int] | None = flat_field("dmd_denoising_steps", None) + dmd_denoising_steps: list[int] | None = None """Timesteps of a few-step distilled (DMD) sampler. ``None`` keeps the model's default.""" - boundary_ratio: float | None = flat_field("boundary_ratio", None) + boundary_ratio: float | None = None """Mixture-of-experts switch point of a two-transformer model. ``None`` keeps the model's default.""" output_type: str = flat_field("output_type", "pil") """Output of the decoding stage: ``pil`` for decoded frames, ``latent`` to skip the VAE decode.""" @@ -331,8 +320,8 @@ class PipelineSelection: @dataclass class GeneratorConfig: - model_path: str = flat_field("model_path") - mode: ExecutionMode = flat_field("mode", ExecutionMode.INFERENCE) + model_path: str + mode: ExecutionMode = ExecutionMode.INFERENCE """What the run does: inference, preprocessing, finetuning, or distillation.""" revision: str | None = flat_field("revision", None) trust_remote_code: bool = flat_field("trust_remote_code", False) diff --git a/fastvideo/api/training_schema.py b/fastvideo/api/training_schema.py index 355860c7b..229a077dd 100644 --- a/fastvideo/api/training_schema.py +++ b/fastvideo/api/training_schema.py @@ -5,10 +5,9 @@ section. Both resolve to a ``ResolvedGeneratorConfig`` through the generator resolution steps plus their own, so the pipelines, loaders, and stages read one runtime config type in every mode. -The field defaults are the effective values of the command line that these runs used: the argparse defaults of the -``TrainingArgs`` and ``FastVideoArgs`` flags, including the engine offload settings, which default to off there -(``CommandLineEngineConfig``). Comma strings of the command line (``betas``, ``validation_sampling_steps``) are typed -tuples and lists here. +The field defaults are the effective values of the training and preprocessing launchers, including the engine +offload settings, which default to off (``CommandLineEngineConfig``). Sequences such as ``betas`` and +``validation.sampling_steps`` are typed tuples and lists. ``load_resolved_run_config`` is the one loader of the entry points: ``--config `` plus dotted overrides such as ``--training.optimizer.learning_rate 1e-5``. @@ -191,8 +190,7 @@ class TrainingOptions: @dataclass class CommandLineOffloadConfig(OffloadConfig): - """Offload settings with the defaults of the ``FastVideoArgs`` command line: every offload and pinned host memory - off.""" + """Offload settings of the training and preprocessing launchers: every offload and pinned host memory off.""" dit: bool = False dit_layerwise: bool = False @@ -204,7 +202,7 @@ class CommandLineOffloadConfig(OffloadConfig): @dataclass class CommandLineEngineConfig(EngineConfig): - """Engine settings with the offload defaults of the ``FastVideoArgs`` command line.""" + """Engine settings with the offload defaults of the training and preprocessing launchers.""" offload: CommandLineOffloadConfig = field(default_factory=CommandLineOffloadConfig) @@ -249,6 +247,14 @@ def resolve_training_offload_conflicts(view: ResolutionView) -> dict[str, Any]: return values +def keep_training_dit_on_device(view: ResolutionView) -> dict[str, Any]: + """A finetuning or distillation run keeps the DiT on the device, so ``engine.offload.dit`` turns off.""" + training = view.get("mode") in (ExecutionMode.FINETUNING, ExecutionMode.DISTILLATION) + if not training or not view.get("engine.offload.dit"): + return {} + return {"engine.offload.dit": False} + + def validate_training_parallel_sizes(view: ResolutionView) -> dict[str, Any]: """Training needs ``hsdp_replicate_dim``, ``hsdp_shard_dim``, and ``sp_size`` set; -1 is not allowed.""" for name in ("hsdp_replicate_dim", "hsdp_shard_dim", "sp_size"): @@ -298,7 +304,7 @@ def training_resolution_steps(config: GeneratorConfig, defaults: Any = None) -> defaults, before_placeholders=(resolve_training_offload_conflicts, validate_training_parallel_sizes), - after=(derive_lora_alpha_from_rank, )) + after=(derive_lora_alpha_from_rank, keep_training_dit_on_device)) def derive_video_preprocess_vae_precision(view: ResolutionView) -> dict[str, Any]: @@ -380,6 +386,7 @@ __all__ = [ "CommandLineOffloadConfig", "derive_lora_alpha_from_rank", "fill_preprocess_model_path", + "keep_training_dit_on_device", "load_resolved_run_config", "preprocess_resolution_steps", "resolve_preprocess_config", diff --git a/fastvideo/configs/AGENTS.md b/fastvideo/configs/AGENTS.md index da17e8cad..e27adcbe1 100644 --- a/fastvideo/configs/AGENTS.md +++ b/fastvideo/configs/AGENTS.md @@ -17,7 +17,6 @@ the layout below. ``` configs/ ├── configs.py # Dataset / loader enums (DatasetType, VideoLoaderType) -├── utils.py # update_config_from_args, shallow_asdict helpers ├── backend/ # Attention backend defaults ├── models/ │ ├── base.py # ModelConfig ABC @@ -57,5 +56,6 @@ If a knob is tunable per inference call → `SamplingParam`, not `PipelineConfig ## Anti-Patterns - Hard-coding architecture constants inside model classes — always read from the arch config. -- Using `argparse` directly here. Configs deserialize from dicts via `update_config_from_args`. +- Using `argparse` directly here. Configs deserialize from JSON files and dicts via `PipelineConfig.from_source` + and `PipelineConfig.update_pipeline_config`. - Importing from `fastvideo.pipelines` here. Configs are the lower layer; the dependency is one-way. diff --git a/fastvideo/configs/configs.py b/fastvideo/configs/configs.py index e780a102d..d46436562 100644 --- a/fastvideo/configs/configs.py +++ b/fastvideo/configs/configs.py @@ -1,10 +1,7 @@ import dataclasses from enum import Enum -from typing import Any, Optional -from fastvideo.configs.utils import update_config_from_args from fastvideo.logger import init_logger -from fastvideo.utils import FlexibleArgumentParser, StoreBoolean logger = init_logger(__name__) @@ -25,11 +22,6 @@ class DatasetType(str, Enum): raise ValueError( f"Invalid dataset type: {value}. Must be one of: {', '.join([m.value for m in cls])}") from None - @classmethod - def choices(cls) -> list[str]: - """Get all available choices as strings for argparse.""" - return [dataset_type.value for dataset_type in cls] - class VideoLoaderType(str, Enum): """ @@ -47,11 +39,6 @@ class VideoLoaderType(str, Enum): raise ValueError( f"Invalid video loader: {value}. Must be one of: {', '.join([m.value for m in cls])}") from None - @classmethod - def choices(cls) -> list[str]: - """Get all available choices as strings for argparse.""" - return [video_loader.value for video_loader in cls] - @dataclasses.dataclass class PreprocessConfig: @@ -96,126 +83,3 @@ class PreprocessConfig: num_latent_t: int = 28 text_max_length: int = 256 cache_dir: str = "./cache_dir" - - @staticmethod - def add_cli_args(parser: FlexibleArgumentParser, prefix: str = "preprocess") -> FlexibleArgumentParser: - """Add preprocessing configuration arguments to the parser.""" - prefix_with_dot = f"{prefix}." if (prefix.strip() != "") else "" - - preprocess_args = parser.add_argument_group("Preprocessing Arguments") - # Model & Dataset - preprocess_args.add_argument(f"--{prefix_with_dot}model-path", - type=str, - default=PreprocessConfig.model_path, - help="Path to the model for preprocessing") - preprocess_args.add_argument(f"--{prefix_with_dot}dataset-path", - type=str, - default=PreprocessConfig.dataset_path, - help="Path to the dataset directory for preprocessing") - preprocess_args.add_argument(f"--{prefix_with_dot}dataset-type", - type=str, - choices=DatasetType.choices(), - default=PreprocessConfig.dataset_type.value, - help="Type of the dataset") - preprocess_args.add_argument(f"--{prefix_with_dot}dataset-output-dir", - type=str, - default=PreprocessConfig.dataset_output_dir, - help="The output directory where the dataset will be written.") - - # Dataloader - preprocess_args.add_argument( - f"--{prefix_with_dot}dataloader-num-workers", - type=int, - default=PreprocessConfig.dataloader_num_workers, - help= - "Number of subprocesses to use for data loading. 0 means that the data will be loaded in the main process.") - preprocess_args.add_argument(f"--{prefix_with_dot}preprocess-video-batch-size", - type=int, - default=PreprocessConfig.preprocess_video_batch_size, - help="Batch size (per device) for the training dataloader.") - - # Saver - preprocess_args.add_argument(f"--{prefix_with_dot}samples-per-file", - type=int, - default=PreprocessConfig.samples_per_file, - help="Number of samples per output file") - preprocess_args.add_argument(f"--{prefix_with_dot}flush-frequency", - type=int, - default=PreprocessConfig.flush_frequency, - help="How often to save to parquet files") - - # Video processing parameters - preprocess_args.add_argument(f"--{prefix_with_dot}video-loader-type", - type=str, - choices=VideoLoaderType.choices(), - default=PreprocessConfig.video_loader_type.value, - help="Type of the video loader") - preprocess_args.add_argument(f"--{prefix_with_dot}max-height", - type=int, - default=PreprocessConfig.max_height, - help="Maximum height for video processing") - preprocess_args.add_argument(f"--{prefix_with_dot}max-width", - type=int, - default=PreprocessConfig.max_width, - help="Maximum width for video processing") - preprocess_args.add_argument(f"--{prefix_with_dot}num-frames", - type=int, - default=PreprocessConfig.num_frames, - help="Number of frames to process") - preprocess_args.add_argument(f"--{prefix_with_dot}video-length-tolerance-range", - type=float, - default=PreprocessConfig.video_length_tolerance_range, - help="Video length tolerance range") - preprocess_args.add_argument(f"--{prefix_with_dot}train-fps", - type=int, - default=PreprocessConfig.train_fps, - help="Training FPS") - preprocess_args.add_argument(f"--{prefix_with_dot}speed-factor", - type=float, - default=PreprocessConfig.speed_factor, - help="Speed factor for video processing") - preprocess_args.add_argument(f"--{prefix_with_dot}drop-short-ratio", - type=float, - default=PreprocessConfig.drop_short_ratio, - help="Ratio for dropping short videos") - preprocess_args.add_argument(f"--{prefix_with_dot}do-temporal-sample", - action=StoreBoolean, - default=PreprocessConfig.do_temporal_sample, - help="Whether to do temporal sampling") - - # Model Training configuration - preprocess_args.add_argument(f"--{prefix_with_dot}training-cfg-rate", - type=float, - default=PreprocessConfig.training_cfg_rate, - help="Training CFG rate") - preprocess_args.add_argument(f"--{prefix_with_dot}with-audio", - action=StoreBoolean, - default=PreprocessConfig.with_audio, - help="Whether to extract and encode audio") - preprocess_args.add_argument(f"--{prefix_with_dot}seed", - type=int, - default=PreprocessConfig.seed, - help="Seed for random number generator") - - return parser - - @classmethod - def from_kwargs(cls, kwargs: dict[str, Any]) -> Optional["PreprocessConfig"]: - """Create PreprocessConfig from keyword arguments.""" - if 'dataset_type' in kwargs and isinstance(kwargs['dataset_type'], str): - kwargs['dataset_type'] = DatasetType.from_string(kwargs['dataset_type']) - if 'video_loader_type' in kwargs and isinstance(kwargs['video_loader_type'], str): - kwargs['video_loader_type'] = VideoLoaderType.from_string(kwargs['video_loader_type']) - - preprocess_config = cls() - if not update_config_from_args(preprocess_config, kwargs, prefix="preprocess", pop_args=True): - return None - return preprocess_config - - def check_preprocess_config(self) -> None: - if self.dataset_path == "": - raise ValueError("dataset_path must be set for preprocess mode") - if self.samples_per_file <= 0: - raise ValueError("samples_per_file must be greater than 0") - if self.flush_frequency <= 0: - raise ValueError("flush_frequency must be greater than 0") diff --git a/fastvideo/configs/models/dits/base.py b/fastvideo/configs/models/dits/base.py index 2342997ad..c840cc9d3 100644 --- a/fastvideo/configs/models/dits/base.py +++ b/fastvideo/configs/models/dits/base.py @@ -1,6 +1,5 @@ # SPDX-License-Identifier: Apache-2.0 from dataclasses import dataclass, field -from typing import Any from fastvideo.configs.models.base import ArchConfig, ModelConfig from fastvideo.layers.quantization import QuantizationConfig @@ -48,24 +47,3 @@ class DiTConfig(ModelConfig): # FastVideoDiT-specific parameters prefix: str = "" quant_config: QuantizationConfig | None = None - - @staticmethod - def add_cli_args(parser: Any, prefix: str = "dit-config") -> Any: - """Add CLI arguments for DiTConfig fields""" - parser.add_argument( - f"--{prefix}.prefix", - type=str, - dest=f"{prefix.replace('-', '_')}.prefix", - default=DiTConfig.prefix, - help="Prefix for the DiT model", - ) - - parser.add_argument( - f"--{prefix}.quant-config", - type=str, - dest=f"{prefix.replace('-', '_')}.quant_config", - default=None, - help="Quantization configuration for the DiT model", - ) - - return parser diff --git a/fastvideo/configs/models/vaes/base.py b/fastvideo/configs/models/vaes/base.py index 864b1be01..e3d0d3db9 100644 --- a/fastvideo/configs/models/vaes/base.py +++ b/fastvideo/configs/models/vaes/base.py @@ -1,13 +1,9 @@ # SPDX-License-Identifier: Apache-2.0 -import argparse -import dataclasses from dataclasses import dataclass, field -from typing import Any import torch from fastvideo.configs.models.base import ArchConfig, ModelConfig -from fastvideo.utils import StoreBoolean @dataclass @@ -44,102 +40,3 @@ class VAEConfig(ModelConfig): def __post_init__(self): self.blend_num_frames = self.tile_sample_min_num_frames - self.tile_sample_stride_num_frames - - @staticmethod - def add_cli_args(parser: Any, prefix: str = "vae-config") -> Any: - """Add CLI arguments for VAEConfig fields""" - parser.add_argument( - f"--{prefix}.load-encoder", - action=StoreBoolean, - dest=f"{prefix.replace('-', '_')}.load_encoder", - default=VAEConfig.load_encoder, - help="Whether to load the VAE encoder", - ) - parser.add_argument( - f"--{prefix}.load-decoder", - action=StoreBoolean, - dest=f"{prefix.replace('-', '_')}.load_decoder", - default=VAEConfig.load_decoder, - help="Whether to load the VAE decoder", - ) - parser.add_argument( - f"--{prefix}.tile-sample-min-height", - type=int, - dest=f"{prefix.replace('-', '_')}.tile_sample_min_height", - default=VAEConfig.tile_sample_min_height, - help="Minimum height for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.tile-sample-min-width", - type=int, - dest=f"{prefix.replace('-', '_')}.tile_sample_min_width", - default=VAEConfig.tile_sample_min_width, - help="Minimum width for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.tile-sample-min-num-frames", - type=int, - dest=f"{prefix.replace('-', '_')}.tile_sample_min_num_frames", - default=VAEConfig.tile_sample_min_num_frames, - help="Minimum number of frames for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.tile-sample-stride-height", - type=int, - dest=f"{prefix.replace('-', '_')}.tile_sample_stride_height", - default=VAEConfig.tile_sample_stride_height, - help="Stride height for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.tile-sample-stride-width", - type=int, - dest=f"{prefix.replace('-', '_')}.tile_sample_stride_width", - default=VAEConfig.tile_sample_stride_width, - help="Stride width for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.tile-sample-stride-num-frames", - type=int, - dest=f"{prefix.replace('-', '_')}.tile_sample_stride_num_frames", - default=VAEConfig.tile_sample_stride_num_frames, - help="Stride number of frames for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.blend-num-frames", - type=int, - dest=f"{prefix.replace('-', '_')}.blend_num_frames", - default=VAEConfig.blend_num_frames, - help="Number of frames to blend for VAE tile sampling", - ) - parser.add_argument( - f"--{prefix}.use-tiling", - action=StoreBoolean, - dest=f"{prefix.replace('-', '_')}.use_tiling", - default=VAEConfig.use_tiling, - help="Whether to use tiling for VAE", - ) - parser.add_argument( - f"--{prefix}.use-temporal-tiling", - action=StoreBoolean, - dest=f"{prefix.replace('-', '_')}.use_temporal_tiling", - default=VAEConfig.use_temporal_tiling, - help="Whether to use temporal tiling for VAE", - ) - parser.add_argument( - f"--{prefix}.use-parallel-tiling", - action=StoreBoolean, - dest=f"{prefix.replace('-', '_')}.use_parallel_tiling", - default=VAEConfig.use_parallel_tiling, - help="Whether to use parallel tiling for VAE", - ) - - return parser - - @classmethod - def from_cli_args(cls, args: argparse.Namespace) -> "VAEConfig": - kwargs = {} - for attr in dataclasses.fields(cls): - value = getattr(args, attr.name, None) - if value is not None: - kwargs[attr.name] = value - return cls(**kwargs) diff --git a/fastvideo/configs/pipelines/base.py b/fastvideo/configs/pipelines/base.py index c12864cd0..7f20a8b36 100644 --- a/fastvideo/configs/pipelines/base.py +++ b/fastvideo/configs/pipelines/base.py @@ -8,9 +8,8 @@ import torch from fastvideo.configs.models import (DiTConfig, EncoderConfig, ModelConfig, VAEConfig, UpsamplerConfig) from fastvideo.configs.models.encoders import BaseEncoderOutput -from fastvideo.configs.utils import update_config_from_args from fastvideo.logger import init_logger -from fastvideo.utils import FlexibleArgumentParser, StoreBoolean, shallow_asdict +from fastvideo.utils import shallow_asdict logger = init_logger(__name__) @@ -100,129 +99,6 @@ class PipelineConfig: add to them.""" object.__setattr__(self, "_frozen", True) - @staticmethod - def add_cli_args(parser: FlexibleArgumentParser, prefix: str = "") -> FlexibleArgumentParser: - prefix_with_dot = f"{prefix}." if (prefix.strip() != "") else "" - - # model_path will be conflicting with the model_path in FastVideoArgs, - # so we add it separately if prefix is not empty - if prefix_with_dot != "": - parser.add_argument( - f"--{prefix_with_dot}model-path", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}model_path", - default=PipelineConfig.model_path, - help="Path to the pretrained model", - ) - - parser.add_argument( - f"--{prefix_with_dot}pipeline-config-path", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}pipeline_config_path", - default=PipelineConfig.pipeline_config_path, - help="Path to the pipeline config", - ) - parser.add_argument( - f"--{prefix_with_dot}embedded-cfg-scale", - type=float, - dest=f"{prefix_with_dot.replace('-', '_')}embedded_cfg_scale", - default=PipelineConfig.embedded_cfg_scale, - help="Embedded CFG scale", - ) - parser.add_argument( - f"--{prefix_with_dot}flow-shift", - type=float, - dest=f"{prefix_with_dot.replace('-', '_')}flow_shift", - default=PipelineConfig.flow_shift, - help="Flow shift parameter", - ) - - # DiT configuration - parser.add_argument( - f"--{prefix_with_dot}dit-precision", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}dit_precision", - default=PipelineConfig.dit_precision, - choices=["fp32", "fp16", "bf16"], - help="Precision for the DiT model", - ) - - # VAE configuration - parser.add_argument( - f"--{prefix_with_dot}vae-precision", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}vae_precision", - default=PipelineConfig.vae_precision, - choices=["fp32", "fp16", "bf16"], - help="Precision for VAE", - ) - parser.add_argument( - f"--{prefix_with_dot}vae-decode-precision", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}vae_decode_precision", - default=PipelineConfig.vae_decode_precision, - choices=["fp32", "fp16", "bf16"], - help="Optional decode-only VAE precision override (falls back to " - "--vae-precision when unset)", - ) - parser.add_argument( - f"--{prefix_with_dot}vae-tiling", - action=StoreBoolean, - dest=f"{prefix_with_dot.replace('-', '_')}vae_tiling", - default=PipelineConfig.vae_tiling, - help="Enable VAE tiling", - ) - parser.add_argument( - f"--{prefix_with_dot}vae-sp", - action=StoreBoolean, - dest=f"{prefix_with_dot.replace('-', '_')}vae_sp", - help="Enable VAE spatial parallelism", - ) - - # Text encoder configuration - parser.add_argument( - f"--{prefix_with_dot}text-encoder-precisions", - nargs="+", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}text_encoder_precisions", - default=PipelineConfig.DEFAULT_TEXT_ENCODER_PRECISIONS, - choices=["fp32", "fp16", "bf16"], - help="Precision for each text encoder", - ) - - # Image encoder configuration - parser.add_argument( - f"--{prefix_with_dot}image-encoder-precision", - type=str, - dest=f"{prefix_with_dot.replace('-', '_')}image_encoder_precision", - default=PipelineConfig.image_encoder_precision, - choices=["fp32", "fp16", "bf16"], - help="Precision for image encoder", - ) - # DMD parameters - parser.add_argument( - f"--{prefix_with_dot}dmd-denoising-steps", - type=parse_int_list, - default=PipelineConfig.dmd_denoising_steps, - help="Comma-separated list of denoising steps (e.g., '1000,757,522')", - ) - - # Add VAE configuration arguments - from fastvideo.configs.models.vaes.base import VAEConfig - VAEConfig.add_cli_args(parser, prefix=f"{prefix_with_dot}vae-config") - - # Add DiT configuration arguments - from fastvideo.configs.models.dits.base import DiTConfig - DiTConfig.add_cli_args(parser, prefix=f"{prefix_with_dot}dit-config") - - return parser - - def update_config_from_dict(self, args: dict[str, Any], prefix: str = "") -> None: - prefix_with_dot = f"{prefix}." if (prefix.strip() != "") else "" - update_config_from_args(self, args, prefix, pop_args=True) - update_config_from_args(self.vae_config, args, f"{prefix_with_dot}vae_config", pop_args=True) - update_config_from_args(self.dit_config, args, f"{prefix_with_dot}dit_config", pop_args=True) - @classmethod def from_pretrained(cls, model_path: str) -> "PipelineConfig": """ @@ -234,49 +110,38 @@ class PipelineConfig: return cast(PipelineConfig, pipeline_config_cls(model_path=model_path)) @classmethod - def from_kwargs(cls, kwargs: dict[str, Any], config_cli_prefix: str = "") -> "PipelineConfig": - """ - Load PipelineConfig from kwargs Dictionary. - kwargs: dictionary of kwargs - config_cli_prefix: prefix of CLI arguments for this PipelineConfig instance + def from_source(cls, + model_path: str, + source: "str | PipelineConfig | dict[str, Any] | None" = None) -> "PipelineConfig": + """Build the registry ``PipelineConfig`` of ``model_path`` and update it from ``source``. + + ``source`` is a JSON file path (loaded and recorded as ``pipeline_config_path``), a mapping of field values, or + a ``PipelineConfig`` that replaces the registry instance. The base ``PipelineConfig`` stands in when the + registry has no class for ``model_path``. An empty path or mapping changes nothing. The result's ``model_path`` + is ``model_path``. """ from fastvideo.registry import get_pipeline_config_cls_from_name - prefix_with_dot = f"{config_cli_prefix}." if (config_cli_prefix.strip() != "") else "" - model_path: str | None = kwargs.get(prefix_with_dot + 'model_path', None) or kwargs.get('model_path') - pipeline_config_or_path: str | PipelineConfig | dict[str, Any] | None = kwargs.get( - prefix_with_dot + 'pipeline_config', None) or kwargs.get('pipeline_config') - if model_path is None: - raise ValueError("model_path is required in kwargs") - - # 1. Get the pipeline config class from the registry pipeline_config_cls = get_pipeline_config_cls_from_name(model_path) - - # 2. Instantiate PipelineConfig if pipeline_config_cls is None: logger.warning("Couldn't find pipeline config for %s. Using the default pipeline config.", model_path) pipeline_config = cls() else: pipeline_config = pipeline_config_cls() - # 3. Load PipelineConfig from a json file or a PipelineConfig object if provided - if isinstance(pipeline_config_or_path, str): - pipeline_config.load_from_json(pipeline_config_or_path) - kwargs[prefix_with_dot + 'pipeline_config_path'] = pipeline_config_or_path - elif isinstance(pipeline_config_or_path, PipelineConfig): - pipeline_config = pipeline_config_or_path - elif isinstance(pipeline_config_or_path, dict): - pipeline_config.update_pipeline_config(pipeline_config_or_path) - - # 4. Update PipelineConfig from CLI arguments if provided - kwargs[prefix_with_dot + 'model_path'] = model_path - pipeline_config.update_config_from_dict(kwargs, config_cli_prefix) - + if isinstance(source, str) and source: + pipeline_config.load_from_json(source) + pipeline_config.pipeline_config_path = source + elif isinstance(source, PipelineConfig): + pipeline_config = source + elif isinstance(source, dict) and source: + pipeline_config.update_pipeline_config(source) + pipeline_config.model_path = model_path return pipeline_config def check_pipeline_config(self) -> None: if self.vae_sp and not self.vae_tiling: - raise ValueError("Currently enabling vae_sp requires enabling vae_tiling, please set --vae-tiling to True.") + raise ValueError("vae_sp requires vae_tiling; set pipeline.vae_tiling to true or pipeline.vae_sp to false.") if len(self.text_encoder_configs) != len(self.text_encoder_precisions): raise ValueError( @@ -345,10 +210,3 @@ class PipelineConfig: if hasattr(self, "__post_init__"): self.__post_init__() - - -def parse_int_list(value: str) -> list[int]: - """Parse a comma-separated string of integers into a list.""" - if not value: - return [] - return [int(x.strip()) for x in value.split(",")] diff --git a/fastvideo/configs/utils.py b/fastvideo/configs/utils.py deleted file mode 100644 index 5222315f6..000000000 --- a/fastvideo/configs/utils.py +++ /dev/null @@ -1,57 +0,0 @@ -import argparse -from typing import Any - - -def update_config_from_args(config: Any, args_dict: dict[str, Any], prefix: str = "", pop_args: bool = False) -> bool: - """ - Update configuration object from arguments dictionary. - - Args: - config: The configuration object to update - args_dict: Dictionary containing arguments - prefix: Prefix for the configuration parameters in the args_dict. - If None, assumes direct attribute mapping without prefix. - """ - # Handle top-level attributes (no prefix) - args_not_to_remove = [ - 'model_path', - ] - args_to_remove = [] - if prefix.strip() == "": - for key, value in args_dict.items(): - if hasattr(config, key) and value is not None: - if key == "text_encoder_precisions" and isinstance(value, list): - setattr(config, key, tuple(value)) - else: - setattr(config, key, value) - if pop_args: - args_to_remove.append(key) - else: - # Handle nested attributes with prefix - prefix_with_dot = f"{prefix}." - for key, value in args_dict.items(): - if key.startswith(prefix_with_dot) and value is not None: - attr_name = key[len(prefix_with_dot):] - if hasattr(config, attr_name): - setattr(config, attr_name, value) - if pop_args: - args_to_remove.append(key) - - if pop_args: - for key in args_to_remove: - if key not in args_not_to_remove: - args_dict.pop(key) - - return len(args_to_remove) > 0 - - -def clean_cli_args(args: argparse.Namespace) -> dict[str, Any]: - """ - Clean the arguments by removing the ones that not explicitly provided by the user. - """ - provided_args = {} - for k, v in vars(args).items(): - if (v is not None and hasattr(args, '_provided') and k in args._provided): - provided_args[k] = v - - return provided_args diff --git a/fastvideo/fastvideo_args.py b/fastvideo/fastvideo_args.py deleted file mode 100644 index f7b9e1861..000000000 --- a/fastvideo/fastvideo_args.py +++ /dev/null @@ -1,1578 +0,0 @@ -# SPDX-License-Identifier: Apache-2.0 -# Inspired by SGLang: https://github.com/sgl-project/sglang/blob/main/python/sglang/srt/server_args.py -"""The arguments of FastVideo Inference.""" -import argparse -import dataclasses -import json -import math -from collections.abc import Mapping -from contextlib import contextmanager -from dataclasses import field -from typing import Any, TYPE_CHECKING - -from fastvideo.api.schema import ExecutionMode, WorkloadType -from fastvideo.configs.configs import PreprocessConfig -from fastvideo.configs.pipelines.base import PipelineConfig -from fastvideo.configs.utils import clean_cli_args -from fastvideo.layers.quantization import QUANTIZATION_METHODS, QuantizationMethods -from fastvideo.logger import init_logger -from fastvideo.utils import FlexibleArgumentParser, StoreBoolean - -if TYPE_CHECKING: - from ray.runtime_env import RuntimeEnv - from ray.util.placement_group import PlacementGroup -else: - RuntimeEnv = Any - PlacementGroup = Any - -logger = init_logger(__name__) - -# Offload flags that trade device memory for host memory. All of them are a loss -# on a device where the two are the same physical pool. Keeping the policy -# centralized lets every loader and stage share one worker-local decision. -UNIFIED_MEMORY_OFFLOAD_FLAGS = ( - "dit_layerwise_offload", - "dit_cpu_offload", - "text_encoder_cpu_offload", - "image_encoder_cpu_offload", - "vae_cpu_offload", -) - - -# args for fastvideo framework -@dataclasses.dataclass -class FastVideoArgs: - # Model and path configuration (for convenience) - model_path: str - - # Running mode - mode: ExecutionMode = ExecutionMode.INFERENCE - - # Workload type - workload_type: WorkloadType = WorkloadType.T2V - - # Distributed executor backend - distributed_executor_backend: str = "mp" - - # a few attributes for ray related - ray_placement_group: PlacementGroup | None = None - ray_runtime_env: RuntimeEnv | None = None - - inference_mode: bool = True # if False == training mode - - # HuggingFace specific parameters - trust_remote_code: bool = False - revision: str | None = None - - # Parallelism - num_gpus: int = 1 - tp_size: int = -1 - sp_size: int = -1 - hsdp_replicate_dim: int = 1 - hsdp_shard_dim: int = -1 - dist_timeout: int | None = None # timeout for torch.distributed - - pipeline_config: PipelineConfig = field(default_factory=PipelineConfig) - preprocess_config: PreprocessConfig | None = None - - # LoRA parameters - # (Wenxuan) prefer to keep it here instead of in pipeline config to not make it complicated. - lora_path: str | None = None - lora_nickname: str = "default" # for swapping adapters in the pipeline - lora_strength: float = 1.0 - # can restrict layers to adapt, e.g. ["q_proj"] - # Will adapt only q, k, v, o by default. - lora_target_modules: list[str] | None = None - - output_type: str = "pil" - - # The attention backend requested for this run. Applied per component at - # load time (each component resolves its own decision, recorded on its - # config); a role-level request (the train stack's per-role - # attention_backend) overrides it. - # - # This field is the parse-once adapter for FASTVIDEO_ATTENTION_BACKEND: - # when left unset it takes the env var's value in __post_init__, so the - # environment is an *input* read once here rather than something the loader - # consults later. None means no request: per-layer defaults, then platform - # auto-selection. - attention_backend: str | None = None - - # CPU offload parameters - dit_cpu_offload: bool = True - use_fsdp_inference: bool = False - dit_layerwise_offload: bool = True - text_encoder_cpu_offload: bool = True - image_encoder_cpu_offload: bool = True - vae_cpu_offload: bool = True - pin_cpu_memory: bool = True - - # MiniMax-H3 inference load order. ``None`` (auto) defers DiT/VAE load until - # after the Qwen3-VL encoder is released, but only on unified-memory - # devices (GB10 / Spark). Discrete GPUs keep the encoder resident so a - # later ``generate()`` on the same worker can re-encode. Explicit True / - # False overrides the probe. Training never defers. - h3_sequential_load: bool | None = None - - # MiniMax-H3 video reconstruction. ``h3-vae`` is the full ViT decoder. - # ``taeh3`` is Ollin Boer Bohan's tiny preview decoder; it changes quality - # and is opt-in. T2VA with TAEH3 does not need the video VAE weights. - video_decode_backend: str = "h3-vae" - taeh3_checkpoint: str | None = None - taeh3_chunk_size: int = 5 - - # Load each heavy component on first use and free it once the last stage - # that holds it has run, instead of keeping every component resident from - # load time to shutdown. Peak memory becomes the largest overlapping set - # rather than the sum of all components. ``None`` (auto) turns this on for - # unified-memory devices (GB10 / Spark) after the worker binds its device, - # and leaves it off on discrete GPUs. Explicit True / False overrides the - # probe. A released component is re-read from disk on the next generation, - # so this trades per-request latency for headroom. Inference only; training - # keeps every component resident. - lazy_module_load: bool | None = None - - # Sequence-parallel MiniMax-H3 VAE (opt-in, default off). With SP > 1 the - # video VAE's temporal chunks (decode) and clips (reference encode) are - # round-robined across the sequence-parallel ranks and reassembled - # bit-exactly on the group's first rank instead of running serially on - # one rank while the others idle. ``__post_init__`` folds the - # FASTVIDEO_VAE_PARALLEL_DECODE / FASTVIDEO_VAE_PARALLEL_ENCODE env vars - # into these fields (parse-once, like attention_backend), and - # FASTVIDEO_VAE_PARALLEL_DECODE_STRATEGY overrides the chunk-transport - # collective ("gather" or "all_gather"). - vae_parallel_decode: bool = False - vae_parallel_encode: bool = False - vae_parallel_decode_strategy: str | None = None - - # Compilation - # ``enable_torch_compile`` covers the DiT path (transformer, - # transformer_2, and the LTX-2 stage-2 transformer_refine). - # Per-component flags below let callers compile additional submodules - # independently; ``False`` leaves the component eager. - enable_torch_compile: bool = False - enable_torch_compile_text_encoder: bool = False - enable_torch_compile_vae: bool = False - enable_torch_compile_audio_vae: bool = False - # ``torch_compile_kwargs`` is the master kwargs dict (applied to every - # compiled submodule unless a per-component dict below is non-empty, - # in which case the per-component dict overrides entirely — matching - # the FastVideo-internal precedent). - torch_compile_kwargs: dict[str, Any] = field(default_factory=dict) - torch_compile_kwargs_dit: dict[str, Any] = field(default_factory=dict) - torch_compile_kwargs_text_encoder: dict[str, Any] = field(default_factory=dict) - torch_compile_kwargs_vae: dict[str, Any] = field(default_factory=dict) - torch_compile_kwargs_audio_vae: dict[str, Any] = field(default_factory=dict) - # Regional (per-transformer-block) fullgraph torch.compile of the DiT at - # inference — the inference-side counterpart of the training regional - # compile ported from hao-ai-lab/FastVideo#1718. Applied by the loader - # right after the transformer loads, with fullgraph=True and inductor - # options {emulate_precision_casts: True} injected (no user kwargs - # needed). MiniMax-H3 VSA is supported only by its compile-safe sm_100a - # tile-64 inference route; other VSA routes degrade the transformer to - # eager with one warning. Dense FA2/FA3/FA4 inference uses compile-visible - # custom-op boundaries. Opt-in via FASTVIDEO_INFERENCE_TORCH_COMPILE=1 (folded in - # __post_init__) or the typed config field engine.compile.regional. - # Distinct from ``enable_torch_compile``, - # which keeps the pipeline-level compile semantics. - inference_torch_compile: bool = False - - disable_autocast: bool = False - - # VSA parameters - VSA_sparsity: float = 0.0 # inference/validation sparsity - VSA_tile_size: int = 256 # VSA-H3 tile size (256 or 64); 64 = native Triton path - - # V-MoBA parameters - moba_config_path: str | None = None - moba_config: dict[str, Any] = field(default_factory=dict) - - # Master port for distributed training/inference - master_port: int | None = None - - # Stage verification - enable_stage_verification: bool = True - - # Prompt text file for batch processing - prompt_txt: str | None = None - - # LTX-2 VAE tiling overrides - ltx2_vae_tiling: bool | None = None - ltx2_vae_spatial_tile_size_in_pixels: int | None = None - ltx2_vae_spatial_tile_overlap_in_pixels: int | None = None - ltx2_vae_temporal_tile_size_in_frames: int | None = None - ltx2_vae_temporal_tile_overlap_in_frames: int | None = None - ltx2_initial_latent_path: str | None = None - ltx2_audio_latent_path: str | None = None - # Generic stage-2 refine surface (preferred user-facing API). The - # ltx2_refine_* fields below remain the runtime carriers; these - # generic ones let CLI / typed-config callers set the same values - # without binding to a specific model family. ``None`` here means - # "fall back to the model_index.json default and/or the - # ltx2_refine_* runtime carrier". - refine_enabled: bool | None = None - refine_upsampler_path: str | None = None - refine_transformer_path: str | None = None - refine_lora_path: str | None = None - refine_num_inference_steps: int | None = None - refine_guidance_scale: float | None = None - refine_add_noise: bool | None = None - refine_noise_path: str | None = None - refine_audio_noise_path: str | None = None - # LTX-2 stage-2 spatial refinement (the SR pipeline). When enabled the - # transformer runs once at half resolution, the latents are upsampled - # by the LTX2 latent upsampler, then a short stage-2 distilled - # denoising pass refines the upsampled latents. Behaviour is opt-in - # and isolated to LTX-2 today. - ltx2_refine_enabled: bool = False - ltx2_refine_upsampler_path: str | None = None - ltx2_refine_transformer_path: str | None = None - ltx2_refine_lora_path: str | None = None - ltx2_refine_num_inference_steps: int = 3 - ltx2_refine_guidance_scale: float = 1.0 - ltx2_refine_add_noise: bool = True - ltx2_refine_noise_path: str | None = None - ltx2_refine_audio_noise_path: str | None = None - ltx2_legacy_native_noise_order: bool = False - ltx2_use_distilled_sigmas: bool = True - - # model paths for correct deallocation - model_paths: dict[str, str] = field(default_factory=dict) - model_loaded: dict[str, bool] = field(default_factory=lambda: { - "transformer": True, - "vae": True, - "upsampler": True, - }) - - override_text_encoder_safetensors: str | None = None # path to safetensors file for text encoder override - override_text_encoder_quant: QuantizationMethods = None - # Typed transformer quantization carrier. The typed inference API - # accepts ``engine.quantization.transformer_quant: "NVFP4"`` and the - # compat layer resolves the name to a concrete ``QuantizationConfig`` - # instance (e.g. ``NVFP4Config()``); ``__post_init__`` then pins it on - # ``pipeline_config.dit_config.quant_config`` so the loader can detect - # FP4 layers via the standard ``get_quant_method`` path. ``None`` - # leaves whatever value the caller already set on ``dit_config`` - # untouched. - transformer_quant: Any | None = None - - override_transformer_cls_name: str | None = None - init_weights_from_safetensors: str = "" # path to safetensors file for initial weight loading - init_weights_from_safetensors_2: str = "" # path to safetensors file for initial weight loading for transformer_2 - - override_pipeline_cls_name: str | None = None - - # # DMD parameters - # dmd_denoising_steps: List[int] | None = field(default=None) - - # MoE parameters used by Wan2.2 - boundary_ratio: float | None = 0.875 - - # The resolved typed config that generator_config_to_fastvideo_args builds this object from. When it is given, - # resolution has already decided the environment folds below, the object keeps the config as - # ``resolved_config``, and after construction its fields change only through override(). - resolved_config: dataclasses.InitVar[Any] = None - - @property - def training_mode(self) -> bool: - return not self.inference_mode - - def __setattr__(self, name: str, value: Any) -> None: - if self.__dict__.get("_frozen") and name in self.__dataclass_fields__ and name not in RUNTIME_STATE_FIELDS: - raise AttributeError(f"FastVideoArgs.{name} was decided by config resolution and is read-only; " - f"use fastvideo_args.override(source, {{{name!r}: value}}) to change it") - super().__setattr__(name, value) - - def override(self, source: str, values: Mapping[str, Any]) -> None: - """Change fields after construction and record the change as ``(source, values)`` in ``override_log``. - - A key is a FastVideoArgs field name, or ``pipeline_config.`` for a PipelineConfig field. On an - object built from a resolved config, the change is also recorded on ``resolved_config`` for every key - whose name a typed config field declares as its flat name. - """ - if not source: - raise ValueError("an override needs a non-empty source name") - typed_values: dict[str, Any] = {} - for key, value in values.items(): - target, name = ((self.pipeline_config, key.split(".", 1)[1]) if key.startswith("pipeline_config.") else - (self, key)) - if name not in target.__dataclass_fields__: - raise AttributeError(f"{type(target).__name__} has no field {name!r}") - object.__setattr__(target, name, value) - typed_path = _typed_path_for_flat_name(name) - if typed_path is not None: - typed_values[typed_path] = value - self.__dict__.setdefault("override_log", []).append((source, dict(values))) - resolved = self.__dict__.get("resolved_config") - if resolved is not None and typed_values: - object.__setattr__(self, "resolved_config", resolved.with_override(source, typed_values)) - - def __post_init__(self, resolved_config: Any = None): - if not math.isfinite(self.lora_strength): - raise ValueError(f"lora_strength must be finite, got {self.lora_strength}") - if self.moba_config_path: - try: - with open(self.moba_config_path) as f: - self.moba_config = json.load(f) - logger.info("Loaded V-MoBA config from %s", self.moba_config_path) - except (FileNotFoundError, json.JSONDecodeError) as e: - logger.error("Failed to load V-MoBA config from %s: %s", self.moba_config_path, e) - raise - self._apply_ltx2_vae_overrides() - self._resolve_refine_args() - self._apply_transformer_quant() - # The env folds below repeat fill_*_from_env in fastvideo/api/inference_resolution.py - # for a FastVideoArgs built directly; a resolved config arrives with the values decided. - fold_environment = resolved_config is None - if fold_environment and not self.inference_torch_compile: - # Parse-once adapter (same pattern as attention_backend below): the - # environment variable is an input read once here, so the loader - # only ever consults the typed field. - import fastvideo.envs as envs - if envs.FASTVIDEO_INFERENCE_TORCH_COMPILE.get(): - self.inference_torch_compile = True - if self.attention_backend is not None: - # Fail fast on typos instead of silently auto-selecting later. - from fastvideo.attention.selector import coerce_attn_backend - coerce_attn_backend(self.attention_backend) - elif fold_environment: - # Parse-once adapter: fold the environment variable into the typed - # request so resolution has a single input and library code never - # consults the environment on the load path. An unsupported name - # raises, like an explicit request. - from fastvideo.attention.selector import get_env_variable_attn_backend - env_backend = get_env_variable_attn_backend() - if env_backend is not None: - self.attention_backend = env_backend.name - self._fold_vae_parallel_env(fold_environment) - import fastvideo.envs as envs - envs.warn_deprecated_variables() - self.check_fastvideo_args() - if resolved_config is not None: - object.__setattr__(self, "resolved_config", resolved_config) - object.__setattr__(self, "_frozen", True) - self.pipeline_config.freeze() - - def _fold_vae_parallel_env(self, fold_environment: bool = True) -> None: - """Parse-once adapters for the sequence-parallel VAE env vars, then validate the decode strategy.""" - import fastvideo.envs as envs - - # Mirrors fastvideo.models.vaes.minimax_h3_parallel.DECODE_GATHER_STRATEGIES / - # DEFAULT_DECODE_GATHER_STRATEGY (kept literal here so constructing args - # never imports model modules; a unit test pins the two in sync). - strategies = ("gather", "all_gather") - if fold_environment: - if not self.vae_parallel_decode and envs.FASTVIDEO_VAE_PARALLEL_DECODE.get(): - self.vae_parallel_decode = True - if not self.vae_parallel_encode and envs.FASTVIDEO_VAE_PARALLEL_ENCODE.get(): - self.vae_parallel_encode = True - if self.vae_parallel_decode_strategy is None: - self.vae_parallel_decode_strategy = envs.FASTVIDEO_VAE_PARALLEL_DECODE_STRATEGY.get() or "gather" - if self.vae_parallel_decode_strategy not in strategies: - raise ValueError(f"vae_parallel_decode_strategy must be one of {strategies}, " - f"got {self.vae_parallel_decode_strategy!r}.") - - def _apply_transformer_quant(self) -> None: - """Pin the typed ``transformer_quant`` instance onto ``dit_config``. - - ``transformer_quant`` is populated by the typed compat layer when - a caller writes ``engine.quantization.transformer_quant: "NVFP4"`` - in their config. We pin it here rather than at request time so - the model loader sees the quant_config when constructing the - DiT (linear layers attach their quant_method during ``__init__``). - """ - if self.transformer_quant is None or self.pipeline_config is None: - return - dit_config = getattr(self.pipeline_config, "dit_config", None) - if dit_config is None: - return - # Resolve a registry name (e.g. "nvfp4_qat_train" from the CLI) to a - # QuantizationConfig instance; a bare string has no get_quant_method. - tq = self.transformer_quant - if isinstance(tq, str): - from fastvideo.layers.quantization import get_quantization_config - tq = get_quantization_config(tq)() - # Don't overwrite if the caller already set it explicitly on - # dit_config (e.g. via ``pipeline_config.dit_config.quant_config = NVFP4Config()``); - # the explicit setter wins. - if getattr(dit_config, "quant_config", None) is None: - dit_config.quant_config = tq - - def _resolve_refine_args(self) -> None: - """Map generic refine_* args to LTX-2-specific refine fields.""" - if self.refine_enabled is not None: - self.ltx2_refine_enabled = self.refine_enabled - if self.refine_upsampler_path is not None: - self.ltx2_refine_upsampler_path = self.refine_upsampler_path - if self.refine_transformer_path is not None: - self.ltx2_refine_transformer_path = self.refine_transformer_path - if self.refine_lora_path is not None: - self.ltx2_refine_lora_path = self.refine_lora_path - if self.refine_num_inference_steps is not None: - self.ltx2_refine_num_inference_steps = self.refine_num_inference_steps - if self.refine_guidance_scale is not None: - self.ltx2_refine_guidance_scale = self.refine_guidance_scale - if self.refine_add_noise is not None: - self.ltx2_refine_add_noise = self.refine_add_noise - if self.refine_noise_path is not None: - self.ltx2_refine_noise_path = self.refine_noise_path - if self.refine_audio_noise_path is not None: - self.ltx2_refine_audio_noise_path = self.refine_audio_noise_path - - def _apply_ltx2_vae_overrides(self) -> None: - if self.pipeline_config is None: - return - vae_config = self.pipeline_config.vae_config - has_any = any(value is not None for value in ( - self.ltx2_vae_spatial_tile_size_in_pixels, - self.ltx2_vae_spatial_tile_overlap_in_pixels, - self.ltx2_vae_temporal_tile_size_in_frames, - self.ltx2_vae_temporal_tile_overlap_in_frames, - )) - if self.ltx2_vae_tiling is not None and hasattr(self.pipeline_config, "vae_tiling"): - self.pipeline_config.vae_tiling = self.ltx2_vae_tiling - # Same rule as derive_vae_tiling_from_ltx2_tile_sizes in fastvideo/api/inference_resolution.py, - # for a FastVideoArgs built directly. - elif has_any and hasattr(self.pipeline_config, "vae_tiling"): - self.pipeline_config.vae_tiling = True - - if hasattr(vae_config, - "ltx2_spatial_tile_size_in_pixels") and self.ltx2_vae_spatial_tile_size_in_pixels is not None: - vae_config.ltx2_spatial_tile_size_in_pixels = (self.ltx2_vae_spatial_tile_size_in_pixels) - if hasattr(vae_config, - "ltx2_spatial_tile_overlap_in_pixels") and self.ltx2_vae_spatial_tile_overlap_in_pixels is not None: - vae_config.ltx2_spatial_tile_overlap_in_pixels = (self.ltx2_vae_spatial_tile_overlap_in_pixels) - if hasattr(vae_config, - "ltx2_temporal_tile_size_in_frames") and self.ltx2_vae_temporal_tile_size_in_frames is not None: - vae_config.ltx2_temporal_tile_size_in_frames = (self.ltx2_vae_temporal_tile_size_in_frames) - if hasattr( - vae_config, - "ltx2_temporal_tile_overlap_in_frames") and self.ltx2_vae_temporal_tile_overlap_in_frames is not None: - vae_config.ltx2_temporal_tile_overlap_in_frames = (self.ltx2_vae_temporal_tile_overlap_in_frames) - - @staticmethod - def add_cli_args(parser: FlexibleArgumentParser) -> FlexibleArgumentParser: - # Model and path configuration - parser.add_argument( - "--model-path", - type=str, - help="The path of the model weights. This can be a local folder or a Hugging Face repo ID.", - ) - - # Running mode - parser.add_argument( - "--mode", - type=str, - choices=ExecutionMode.choices(), - default=FastVideoArgs.mode.value, - help="The mode to run FastVideo", - ) - - # Workload type - parser.add_argument( - "--workload-type", - type=str, - choices=WorkloadType.choices(), - default=FastVideoArgs.workload_type.value, - help="The workload type", - ) - - # distributed_executor_backend - parser.add_argument( - "--distributed-executor-backend", - type=str, - choices=["mp"], - default=FastVideoArgs.distributed_executor_backend, - help="The distributed executor backend to use", - ) - - parser.add_argument( - "--inference-mode", - action=StoreBoolean, - default=FastVideoArgs.inference_mode, - help="Whether to use inference mode", - ) - - # HuggingFace specific parameters - parser.add_argument( - "--trust-remote-code", - action=StoreBoolean, - default=FastVideoArgs.trust_remote_code, - help="Trust remote code when loading HuggingFace models", - ) - parser.add_argument( - "--revision", - type=str, - default=FastVideoArgs.revision, - help="The specific model version to use (can be a branch name, tag name, or commit id)", - ) - - # Parallelism - parser.add_argument( - "--num-gpus", - type=int, - default=FastVideoArgs.num_gpus, - help="The number of GPUs to use.", - ) - parser.add_argument( - "--tp-size", - type=int, - default=FastVideoArgs.tp_size, - help="The tensor parallelism size.", - ) - parser.add_argument( - "--sp-size", - type=int, - default=FastVideoArgs.sp_size, - help="The sequence parallelism size.", - ) - parser.add_argument( - "--hsdp-replicate-dim", - type=int, - default=FastVideoArgs.hsdp_replicate_dim, - help="The data parallelism size.", - ) - parser.add_argument( - "--hsdp-shard-dim", - type=int, - default=FastVideoArgs.hsdp_shard_dim, - help="The data parallelism shards.", - ) - parser.add_argument( - "--dist-timeout", - type=int, - default=FastVideoArgs.dist_timeout, - help="Set timeout for torch.distributed initialization.", - ) - - # Output type - parser.add_argument( - "--output-type", - type=str, - default=FastVideoArgs.output_type, - choices=["pil"], - help="Output type for the generated video", - ) - - # Attention backend (process-wide default request) - parser.add_argument( - "--attention-backend", - type=str, - default=FastVideoArgs.attention_backend, - help="Default attention backend request (e.g. FLASH_ATTN, TORCH_SDPA, " - "SAGE_ATTN). Applied per component at load time; component/role-level " - "requests override it. Unset: FASTVIDEO_ATTENTION_BACKEND env var, " - "then per-layer defaults, then automatic selection.", - ) - - # Prompt text file for batch processing - parser.add_argument( - "--prompt-txt", - type=str, - default=FastVideoArgs.prompt_txt, - help="Path to a text file containing prompts (one per line) for batch processing", - ) - - # LTX-2 VAE tiling overrides - parser.add_argument( - "--ltx2-vae-tiling", - action=StoreBoolean, - default=FastVideoArgs.ltx2_vae_tiling, - help="Enable LTX-2 VAE tiling overrides.", - ) - parser.add_argument( - "--ltx2-vae-spatial-tile-size-in-pixels", - type=int, - default=FastVideoArgs.ltx2_vae_spatial_tile_size_in_pixels, - help="LTX-2 VAE spatial tile size in pixels.", - ) - parser.add_argument( - "--ltx2-vae-spatial-tile-overlap-in-pixels", - type=int, - default=FastVideoArgs.ltx2_vae_spatial_tile_overlap_in_pixels, - help="LTX-2 VAE spatial tile overlap in pixels.", - ) - parser.add_argument( - "--ltx2-vae-temporal-tile-size-in-frames", - type=int, - default=FastVideoArgs.ltx2_vae_temporal_tile_size_in_frames, - help="LTX-2 VAE temporal tile size in frames.", - ) - parser.add_argument( - "--ltx2-vae-temporal-tile-overlap-in-frames", - type=int, - default=FastVideoArgs.ltx2_vae_temporal_tile_overlap_in_frames, - help="LTX-2 VAE temporal tile overlap in frames.", - ) - parser.add_argument( - "--ltx2-initial-latent-path", - type=str, - default=FastVideoArgs.ltx2_initial_latent_path, - help="Path to load/save a precomputed LTX-2 initial latent.", - ) - - # LoRA parameters (inference-time adapter loading) - parser.add_argument( - "--lora-path", - type=str, - default=FastVideoArgs.lora_path, - help="Path to a LoRA adapter (directory or HF repo id). If set, LoRA will be applied at inference.", - ) - parser.add_argument( - "--lora-nickname", - type=str, - default=FastVideoArgs.lora_nickname, - help="Nickname to refer to the loaded LoRA adapter (useful for swapping).", - ) - parser.add_argument( - "--lora-strength", - type=float, - default=FastVideoArgs.lora_strength, - help="Scale applied to every part of the inference LoRA adapter (default: 1.0).", - ) - parser.add_argument( - "--lora-target-modules", - nargs="+", - type=str, - default=FastVideoArgs.lora_target_modules, - help="Optional list of module name substrings to restrict LoRA injection (e.g. q_proj k_proj v_proj).", - ) - - # BSA runtime control (LongCat) - parser.add_argument( - "--enable-bsa", - action=StoreBoolean, - help="Enable Block Sparse Attention (BSA) at runtime (overrides config).", - ) - parser.add_argument( - "--bsa-sparsity", - type=float, - help="BSA sparsity (e.g., 0.9375).", - ) - parser.add_argument( - "--bsa-cdf-threshold", - type=float, - help="BSA CDF threshold (optional).", - ) - parser.add_argument( - "--bsa-chunk-q", - nargs=3, - type=int, - metavar=("T", "H", "W"), - help="BSA chunk_3d_shape_q as three ints, e.g., 4 4 4.", - ) - parser.add_argument( - "--bsa-chunk-k", - nargs=3, - type=int, - metavar=("T", "H", "W"), - help="BSA chunk_3d_shape_k as three ints, e.g., 4 4 4.", - ) - - parser.add_argument( - "--enable-torch-compile", - action=StoreBoolean, - default=FastVideoArgs.enable_torch_compile, - help="Use torch.compile to speed up DiT inference." + - "However, will likely cause precision drifts. See (https://github.com/pytorch/pytorch/issues/145213)", - ) - parser.add_argument( - "--torch-compile-kwargs", - type=str, - default=None, - help= - "JSON string of kwargs to pass to torch.compile. Example: '{\"backend\":\"inductor\",\"mode\":\"reduce-overhead\"}'", - ) - parser.add_argument( - "--inference-torch-compile", - action=StoreBoolean, - default=FastVideoArgs.inference_torch_compile, - help="Regional fullgraph torch.compile of each DiT transformer block at inference " - "(port of the #1718 training-side regional compile). The loader injects fullgraph=True " - "and inductor options {emulate_precision_casts: true}; non-traceable attention backends " - "(VSA) degrade to eager with one warning. FASTVIDEO_INFERENCE_TORCH_COMPILE=1 is equivalent.", - ) - - parser.add_argument( - "--dit-cpu-offload", - action=StoreBoolean, - help="Use CPU offload for DiT inference. Enable if run out of memory with FSDP.", - ) - parser.add_argument( - "--dit-layerwise-offload", - action=StoreBoolean, - help="Enable layerwise CPU offload with async H2D prefetch overlap.", - ) - parser.add_argument( - "--use-fsdp-inference", - action=StoreBoolean, - help= - "Use FSDP for inference by sharding the model weights. FSDP helps reduce GPU memory usage but may introduce" - + " weight transfer overhead depending on the specific setup. Enable if run out of memory.", - ) - parser.add_argument( - "--text-encoder-cpu-offload", - action=StoreBoolean, - help="Use CPU offload for text encoder. Enable if run out of memory.", - ) - parser.add_argument( - "--image-encoder-cpu-offload", - action=StoreBoolean, - help="Use CPU offload for image encoder. Enable if run out of memory.", - ) - parser.add_argument( - "--vae-cpu-offload", - action=StoreBoolean, - help="Use CPU offload for VAE. Enable if run out of memory.", - ) - parser.add_argument( - "--lazy-module-load", - action=argparse.BooleanOptionalAction, - default=None, - help="Load each heavy component on first use and free it after the last stage that needs it, " - "so peak memory is the largest overlapping set of components instead of their sum. " - "Omit for auto (on for unified-memory devices such as GB10; off on discrete GPUs). " - "Pass --no-lazy-module-load to keep every component resident.", - ) - parser.add_argument( - "--pin-cpu-memory", - action=StoreBoolean, - help= - "Pin memory for CPU offload. Only added as a temp workaround if it throws \"CUDA error: invalid argument\". " - "Should be enabled in almost all cases", - ) - parser.add_argument( - "--h3-sequential-load", - action=argparse.BooleanOptionalAction, - default=None, - help="MiniMax-H3: encode with Qwen3-VL, release that encoder, then load DiT and VAEs. " - "Omit for auto (on for unified-memory devices such as GB10; off on discrete GPUs). " - "Pass --no-h3-sequential-load to keep the encoder resident for later generate() calls.", - ) - parser.add_argument( - "--video-decode-backend", - type=str, - choices=("h3-vae", "taeh3"), - default=FastVideoArgs.video_decode_backend, - help="MiniMax-H3 video decoder. taeh3 is a fast approximate preview decoder; h3-vae is the full VAE.", - ) - parser.add_argument( - "--taeh3-checkpoint", - type=str, - default=None, - help="Local taeh3.safetensors path. Unset downloads the pinned upstream weights into the cache.", - ) - parser.add_argument( - "--taeh3-chunk-size", - type=int, - default=FastVideoArgs.taeh3_chunk_size, - help="TAEH3 latent frames per execution chunk.", - ) - parser.add_argument( - "--vae-parallel-decode", - action=StoreBoolean, - help="With sequence parallelism, round-robin MiniMax-H3 VAE decode chunks across the SP ranks " - "and reassemble bit-exactly on the output rank (default: serial decode on the output rank)", - ) - parser.add_argument( - "--vae-parallel-encode", - action=StoreBoolean, - help="With sequence parallelism, round-robin MiniMax-H3 reference-video VAE encode clips across " - "the SP ranks; every rank keeps the identical full encoding (default: serial encode on every rank)", - ) - parser.add_argument( - "--disable-autocast", - action=StoreBoolean, - help="Disable autocast for denoising loop and vae decoding in pipeline sampling", - ) - - # VSA parameters - parser.add_argument( - "--VSA-sparsity", - type=float, - default=FastVideoArgs.VSA_sparsity, - help="Validation sparsity for VSA", - ) - parser.add_argument( - "--VSA-tile-size", - type=int, - default=FastVideoArgs.VSA_tile_size, - help="VSA-H3 tile size in tokens (256 or 64); 64 runs the native Triton block-sparse path", - ) - - # Master port for distributed training/inference - parser.add_argument( - "--master-port", - type=int, - default=FastVideoArgs.master_port, - help="Master port for distributed training/inference", - ) - - # Stage verification - parser.add_argument( - "--enable-stage-verification", - action=StoreBoolean, - default=FastVideoArgs.enable_stage_verification, - help="Enable input/output verification for pipeline stages", - ) - parser.add_argument( - "--override-text-encoder-safetensors", - type=str, - default=FastVideoArgs.override_text_encoder_safetensors, - help="Path to safetensors file for text encoder override", - ) - parser.add_argument( - "--override-text-encoder-quant", - type=str, - choices=QUANTIZATION_METHODS, - default=FastVideoArgs.override_text_encoder_quant, - help="Quantization method for text encoder override", - ) - parser.add_argument( - "--override-transformer-cls-name", - type=str, - default=FastVideoArgs.override_transformer_cls_name, - help="Override transformer cls name", - ) - parser.add_argument( - "--override-pipeline-cls-name", - type=str, - default=FastVideoArgs.override_pipeline_cls_name, - help="Override pipeline cls name", - ) - parser.add_argument("--init-weights-from-safetensors", - type=str, - help="Path to safetensors file for initial weight loading") - parser.add_argument("--init-weights-from-safetensors-2", - type=str, - help="Path to safetensors file for initial weight loading") - - # Add pipeline configuration arguments - PipelineConfig.add_cli_args(parser) - - # Add preprocessing configuration arguments - PreprocessConfig.add_cli_args(parser) - - return parser - - @classmethod - def from_cli_args(cls, args: argparse.Namespace) -> "FastVideoArgs": - provided_args = clean_cli_args(args) - # Get all fields from the dataclass - attrs = [attr.name for attr in dataclasses.fields(cls)] - - # Create a dictionary of attribute values, with defaults for missing attributes - kwargs: dict[str, Any] = {} - for attr in attrs: - if attr == 'pipeline_config': - pipeline_config = PipelineConfig.from_kwargs(provided_args) - kwargs['pipeline_config'] = pipeline_config - elif attr == 'preprocess_config': - preprocess_config = PreprocessConfig.from_kwargs(provided_args) - kwargs['preprocess_config'] = preprocess_config - elif attr == 'mode': - # Convert string to ExecutionMode enum - mode_value = getattr(args, attr, FastVideoArgs.mode.value) - kwargs['mode'] = ExecutionMode.from_string(mode_value) if isinstance(mode_value, str) else mode_value - elif attr == 'torch_compile_kwargs': - # Parse JSON string for torch.compile kwargs - torch_compile_kwargs_str = getattr(args, 'torch_compile_kwargs', None) - if torch_compile_kwargs_str: - try: - import json - kwargs['torch_compile_kwargs'] = json.loads(torch_compile_kwargs_str) - except json.JSONDecodeError as e: - raise ValueError(f"Invalid JSON for torch_compile_kwargs: {e}") from e - else: - kwargs['torch_compile_kwargs'] = {} - elif attr == 'workload_type': - # Convert string to WorkloadType enum - workload_type_value = getattr(args, 'workload_type', FastVideoArgs.workload_type.value) - kwargs['workload_type'] = WorkloadType.from_string(workload_type_value) if isinstance( - workload_type_value, str) else workload_type_value - # Use getattr with default value from the dataclass for potentially missing attributes - else: - # Get the field to check if it has a default_factory - field = dataclasses.fields(cls)[next(i for i, f in enumerate(dataclasses.fields(cls)) - if f.name == attr)] - if field.default_factory is not dataclasses.MISSING: - # Use the default_factory to create the default value - default_value = field.default_factory() - else: - default_value = getattr(cls, attr, None) - value = getattr(args, attr, default_value) - kwargs[attr] = value # type: ignore - - return cls(**kwargs) # type: ignore - - @classmethod - def from_kwargs(cls, **kwargs: Any) -> "FastVideoArgs": - # Convert mode string to enum if necessary - if 'mode' in kwargs and isinstance(kwargs['mode'], str): - kwargs['mode'] = ExecutionMode.from_string(kwargs['mode']) - - # Convert workload_type string to enum if necessary - if 'workload_type' in kwargs and isinstance(kwargs['workload_type'], str): - kwargs['workload_type'] = WorkloadType.from_string(kwargs['workload_type']) - - kwargs['pipeline_config'] = PipelineConfig.from_kwargs(kwargs) - kwargs['preprocess_config'] = PreprocessConfig.from_kwargs(kwargs) - # Filter to only FastVideoArgs dataclass fields — pipeline-specific CLI - # args (e.g. enable_bsa, bsa_sparsity) live in PipelineConfig and must - # not be forwarded to the FastVideoArgs constructor. - valid_fields = {f.name for f in dataclasses.fields(cls)} | {"resolved_config"} - return cls(**{k: v for k, v in kwargs.items() if k in valid_fields}) - - def check_fastvideo_args(self) -> None: - """Validate inference arguments for consistency""" - # Validate mode and inference_mode consistency - assert isinstance(self.mode, ExecutionMode), f"Mode must be an ExecutionMode enum, got {type(self.mode)}" - assert self.mode in ExecutionMode.choices(), f"Invalid execution mode: {self.mode}" - - # Validate workload type - assert isinstance(self.workload_type, - WorkloadType), f"Workload type must be a WorkloadType enum, got {type(self.workload_type)}" - assert self.workload_type in WorkloadType.choices(), f"Invalid workload type: {self.workload_type}" - - if self.mode in [ExecutionMode.DISTILLATION, ExecutionMode.FINETUNING] and self.inference_mode: - logger.warning("Mode is 'training' but inference_mode is True. Setting inference_mode to False.") - self.inference_mode = False - elif self.mode in [ExecutionMode.INFERENCE, ExecutionMode.PREPROCESS] and not self.inference_mode: - logger.warning("Mode is '%s' but inference_mode is False. Setting inference_mode to True.", self.mode) - self.inference_mode = True - - # Inference policy must wait until a worker owns and binds its device: - # a unified-memory device disables layerwise offload before conflicts - # are resolved, preserving an explicit FSDP request. Training does not - # pass through the inference worker boundary, so retain its historical - # constructor-time normalization. - if not self.inference_mode: - self._resolve_device_offload_conflicts() - - if not self.inference_mode: - assert self.hsdp_replicate_dim != -1, "hsdp_replicate_dim must be set for training" - assert self.hsdp_shard_dim != -1, "hsdp_shard_dim must be set for training" - assert self.sp_size != -1, "sp_size must be set for training" - - # Same rule as derive_parallel_sizes in fastvideo/api/inference_resolution.py, - # for a FastVideoArgs built directly. - if self.tp_size == -1: - self.tp_size = 1 - if self.sp_size == -1: - self.sp_size = self.num_gpus - if self.hsdp_shard_dim == -1: - self.hsdp_shard_dim = self.num_gpus - - assert self.sp_size <= self.num_gpus and self.num_gpus % self.sp_size == 0, "num_gpus must >= and be divisible by sp_size" - assert self.hsdp_replicate_dim <= self.num_gpus and self.num_gpus % self.hsdp_replicate_dim == 0, "num_gpus must >= and be divisible by hsdp_replicate_dim" - assert self.hsdp_shard_dim <= self.num_gpus and self.num_gpus % self.hsdp_shard_dim == 0, "num_gpus must >= and be divisible by hsdp_shard_dim" - - if self.num_gpus < max(self.tp_size, self.sp_size): - self.num_gpus = max(self.tp_size, self.sp_size) - - if self.pipeline_config is None: - raise ValueError("pipeline_config is not set in FastVideoArgs") - - self.pipeline_config.check_pipeline_config() - - # Add preprocessing config validation if needed - if self.mode == ExecutionMode.PREPROCESS: - if self.preprocess_config is None: - raise ValueError("preprocess_config is not set in FastVideoArgs when mode is PREPROCESS") - if self.preprocess_config.model_path == "": - self.preprocess_config.model_path = self.model_path - if not self.pipeline_config.vae_config.load_encoder: - self.pipeline_config.vae_config.load_encoder = True - self.preprocess_config.check_preprocess_config() - - def _resolve_device_offload_conflicts(self) -> None: - """Resolve offload modes after device-local policy has been applied.""" - from fastvideo.platforms import current_platform - - if current_platform.is_mps(): - self.override("device_policy:mps", {"use_fsdp_inference": False, "dit_layerwise_offload": False}) - - if self.dit_layerwise_offload: - if self.use_fsdp_inference: - logger.warning("dit_layerwise_offload is enabled, automatically disabling use_fsdp_inference.") - self.override("device_policy:layerwise_offload", {"use_fsdp_inference": False}) - if self.dit_cpu_offload: - logger.warning("dit_layerwise_offload is enabled, automatically disabling dit_cpu_offload.") - self.override("device_policy:layerwise_offload", {"dit_cpu_offload": False}) - - def finalize_device_offload_policy(self, device_id: int = 0) -> bool: - """Apply device-local memory policy, then resolve incompatible modes.""" - has_unified_memory = self.disable_offload_on_unified_memory(device_id) - if self.lazy_module_load is None: - self.override("device_policy:lazy_module_load", - {"lazy_module_load": bool(has_unified_memory) and not self.training_mode}) - if self.lazy_module_load: - from fastvideo.platforms import current_platform - - try: - device_name = current_platform.get_device_name(device_id) - except Exception: - device_name = current_platform.device_name - logger.info( - "Enabling lazy_module_load: %s has unified memory, so encoder, DiT, and VAEs cannot stay " - "resident together. Pass --no-lazy-module-load to keep every component loaded.", - device_name, - ) - self._resolve_device_offload_conflicts() - return has_unified_memory - - def disable_offload_on_unified_memory(self, device_id: int = 0, *, offload_flag: str | None = None) -> bool: - """Disable host offload after a worker has selected its device. - - CUDA's unified-memory probe reads runtime device properties and may - initialize a CUDA context. Callers must therefore use this only inside - a device-owning process, after selecting and binding ``device_id``. - Returning the classification lets direct component-loader callers - apply the same policy to explicit per-call overrides. When - ``offload_flag`` is given, the return value says whether this policy - covers that component role. - """ - from fastvideo.platforms import current_platform - - cached_device_id = getattr(self, "_unified_memory_device_id", None) - cached_result = getattr(self, "_unified_memory_result", None) - if cached_device_id != device_id or cached_result is None: - cached_result = current_platform.has_unified_memory(device_id) - self._unified_memory_device_id = device_id - self._unified_memory_result = cached_result - - if not cached_result: - return False - - enabled_flags = [flag for flag in UNIFIED_MEMORY_OFFLOAD_FLAGS if getattr(self, flag)] - if enabled_flags: - try: - device_name = current_platform.get_device_name(device_id) - except Exception: - # Device naming is diagnostic only. NVML can be unavailable on - # an integrated GPU (for example Jetson), and its physical- - # ordinal lookup cannot interpret CUDA_VISIBLE_DEVICES UUID/MIG - # selectors. Neither case should undo an authoritative driver - # classification. - device_name = current_platform.device_name - - for flag in enabled_flags: - logger.info( - "Disabling %s: %s has unified memory, so moving weights to the host duplicates " - "them rather than freeing device memory.", flag, device_name) - self.override("device_policy:unified_memory", dict.fromkeys(enabled_flags, False)) - return offload_flag is None or offload_flag in UNIFIED_MEMORY_OFFLOAD_FLAGS - - -# Fields that hold runtime state rather than configuration, so code may set them after construction. -RUNTIME_STATE_FIELDS = frozenset({"model_paths", "model_loaded", "ray_placement_group", "ray_runtime_env"}) - - -def _typed_path_for_flat_name(flat_name: str) -> str | None: - """Dotted GeneratorConfig path of the typed field whose flat name is ``flat_name``, if there is one.""" - from fastvideo.api.compat import _FLAT_NAME_FIELDS - - entry = _FLAT_NAME_FIELDS.get(flat_name) - return None if entry is None else entry[0] - - -_current_fastvideo_args = None - - -def prepare_fastvideo_args(argv: list[str]) -> FastVideoArgs: - """ - Prepare the inference arguments from the command line arguments. - - Args: - argv: The command line arguments. Typically, it should be `sys.argv[1:]` - to ensure compatibility with `parse_args` when no arguments are passed. - - Returns: - The inference arguments. - """ - parser = FlexibleArgumentParser() - FastVideoArgs.add_cli_args(parser) - raw_args = parser.parse_args(argv) - fastvideo_args = FastVideoArgs.from_cli_args(raw_args) - global _current_fastvideo_args - _current_fastvideo_args = fastvideo_args - return fastvideo_args - - -@contextmanager -def set_current_fastvideo_args(fastvideo_args: FastVideoArgs): - """ - Temporarily set the current fastvideo config. - Used during model initialization. - We save the current fastvideo config in a global variable, - so that all modules can access it, e.g. custom ops - can access the fastvideo config to determine how to dispatch. - """ - global _current_fastvideo_args - old_fastvideo_args = _current_fastvideo_args - try: - _current_fastvideo_args = fastvideo_args - yield - finally: - _current_fastvideo_args = old_fastvideo_args - - -def get_current_fastvideo_args() -> FastVideoArgs: - if _current_fastvideo_args is None: - # in ci, usually when we test custom ops/modules directly, - # we don't set the fastvideo config. In that case, we set a default - # config. - # TODO(will): may need to handle this for CI. - raise ValueError("Current fastvideo args is not set.") - return _current_fastvideo_args - - -@dataclasses.dataclass -class TrainingArgs(FastVideoArgs): - """ - Training arguments. Inherits from FastVideoArgs and adds training-specific - arguments. If there are any conflicts, the training arguments will take - precedence. - """ - data_path: str = "" - dataloader_num_workers: int = 0 - num_height: int = 0 - num_width: int = 0 - num_frames: int = 0 - - train_batch_size: int = 0 - num_latent_t: int = 0 - group_frame: bool = False - group_resolution: bool = False - - # text encoder & vae & diffusion model - pretrained_model_name_or_path: str = "" - - # DMD model paths - separate paths for each network - real_score_model_path: str = "" # path for real score (teacher) model - fake_score_model_path: str = "" # path for fake score (critic) model - - # diffusion setting - ema_decay: float = 0.0 - ema_start_step: int = 0 - training_cfg_rate: float = 0.0 - precondition_outputs: bool = False - - # validation & logs - validation_dataset_file: str = "" - validation_preprocessed_path: str = "" - validation_sampling_steps: str = "" - validation_guidance_scale: str = "" - validation_steps: float = 0.0 - log_validation: bool = False - trackers: list[str] = dataclasses.field(default_factory=list) - tracker_project_name: str = "" - wandb_run_name: str = "" - seed: int | None = None - - # output - output_dir: str = "" - checkpoints_total_limit: int = 0 - resume_from_checkpoint: str = "" # specify the checkpoint folder to resume from - - # optimizer & scheduler - num_train_epochs: int = 0 - max_train_steps: int = 0 - gradient_accumulation_steps: int = 0 - learning_rate: float = 0.0 - scale_lr: bool = False - lr_scheduler: str = "constant" - lr_warmup_steps: int = 0 - max_grad_norm: float = 0.0 - enable_gradient_checkpointing_type: str | None = None - selective_checkpointing: float = 0.0 - mixed_precision: str = "" - train_sp_batch_size: int = 0 - fsdp_sharding_startegy: str = "" - - weighting_scheme: str = "" - logit_mean: float = 0.0 - logit_std: float = 1.0 - mode_scale: float = 0.0 - - num_euler_timesteps: int = 0 - lr_num_cycles: int = 0 - lr_power: float = 0.0 - min_lr_ratio: float = 0.5 # minimum learning rate ratio for cosine_with_min_lr scheduler - not_apply_cfg_solver: bool = False - distill_cfg: float = 0.0 - scheduler_type: str = "" - linear_quadratic_threshold: float = 0.0 - linear_range: float = 0.0 - weight_decay: float = 0.0 - betas: str = "0.9,0.999" # betas for optimizer, format: "beta1,beta2" - use_ema: bool = False - multi_phased_distill_schedule: str = "" - pred_decay_weight: float = 0.0 - pred_decay_type: str = "" - hunyuan_teacher_disable_cfg: bool = False - - # master_weight_type - master_weight_type: str = "" - - # VSA training decay parameters - VSA_decay_rate: float = 0.01 # decay rate -> 0.02 - VSA_decay_interval_steps: int = 1 # decay interval steps -> 50 - # Reuse the per-step padded VSA tile buffer across attention layers during - # training. Defaults to False: under full activation checkpointing the - # cached buffer survives into the backward recompute and inflates peak - # memory (see #1423). Enable on memory-rich setups to keep the per-step - # buffer-reuse speedup. - VSA_cache_tile_buf: bool = False - - # LoRA training parameters - lora_rank: int | None = None - lora_alpha: int | None = None - lora_training: bool = False - ltx2_first_frame_conditioning_p: float = 0.1 - - # distillation args - generator_update_interval: int = 5 - dfake_gen_update_ratio: int = 5 # self-forcing: how often to train generator vs critic - min_timestep_ratio: float = 0.2 - max_timestep_ratio: float = 0.98 - # CFG scale applied to the real (teacher) score in the DMD loss, using the - # parameterization `x = x_cond + w * (x_cond - x_uncond)`. This differs - # from the Ho & Salimans form `x_uncond + w * (x_cond - x_uncond)` by an - # offset of 1: `w_here = w_standard - 1`. So `w=0` recovers the - # conditional output, `w=-1` recovers the unconditional output, and the - # default 3.5 corresponds to a standard CFG scale of 4.5. Matches the - # original DMD2 reference implementation. - real_score_guidance_scale: float = 3.5 - fake_score_learning_rate: float = 0.0 # separate learning rate for fake_score_transformer, if 0.0, use learning_rate - fake_score_lr_scheduler: str = "constant" # separate lr scheduler for fake_score_transformer, if not set, use lr_scheduler - fake_score_betas: str = "0.9,0.999" # betas for fake score optimizer, format: "beta1,beta2" - training_state_checkpointing_steps: int = 0 # for resuming training - weight_only_checkpointing_steps: int = 0 # for inference - log_visualization: bool = False - visualization_steps: int = 0 - # simulate generator forward to match inference - simulate_generator_forward: bool = False - warp_denoising_step: bool = False - - # Self-forcing specific arguments - num_frame_per_block: int = 3 - independent_first_frame: bool = False - enable_gradient_masking: bool = True - gradient_mask_last_n_frames: int = 21 - same_step_across_blocks: bool = False # Use same exit timestep for all blocks - last_step_only: bool = False # Only use the last timestep for training - context_noise: int = 0 # Context noise level for cache updates - - @classmethod - def from_cli_args(cls, args: argparse.Namespace) -> "TrainingArgs": - provided_args = clean_cli_args(args) - # Get all fields from the dataclass - attrs = [attr.name for attr in dataclasses.fields(cls)] - logger.info(provided_args) - # Create a dictionary of attribute values, with defaults for missing attributes - kwargs: dict[str, Any] = {} - for attr in attrs: - if attr == 'pipeline_config': - pipeline_config = PipelineConfig.from_kwargs(provided_args) - kwargs[attr] = pipeline_config - elif attr == 'mode': - # Convert string to ExecutionMode enum - mode_value = getattr(args, attr, ExecutionMode.FINETUNING.value) - kwargs[attr] = ExecutionMode.from_string(mode_value) if isinstance(mode_value, str) else mode_value - elif attr == 'workload_type': - # Convert string to WorkloadType enum - workload_type_value = getattr(args, 'workload_type', WorkloadType.T2V.value) - kwargs[attr] = WorkloadType.from_string(workload_type_value) if isinstance(workload_type_value, - str) else workload_type_value - # Use getattr with default value from the dataclass for potentially missing attributes - else: - # Get the field to check its default value - field = dataclasses.fields(cls)[next(i for i, f in enumerate(dataclasses.fields(cls)) - if f.name == attr)] - - # Check if the attribute is provided in args - if hasattr(args, attr): - value = getattr(args, attr) - else: - # Use the field's default value - if field.default_factory is not dataclasses.MISSING: - value = field.default_factory() - elif field.default is not dataclasses.MISSING: - value = field.default - else: - # No default value, use None - value = None - - kwargs[attr] = value - - return cls(**kwargs) # type: ignore - - @staticmethod - def add_cli_args(parser: FlexibleArgumentParser) -> FlexibleArgumentParser: - parser.add_argument("--data-path", type=str, required=True, help="Path to parquet files") - parser.add_argument("--transformer-quant", - type=str, - default=None, - help="Quantization config name for the DiT (e.g. nvfp4_qat_train for " - "QAT-finetune FP4 linear with a straight-through estimator). " - "Resolved to a QuantizationConfig and pinned on dit_config.quant_config.") - parser.add_argument("--dataloader-num-workers", - type=int, - required=True, - help="Number of workers for dataloader") - parser.add_argument("--num-height", type=int, required=True, help="Number of heights") - parser.add_argument("--num-width", type=int, required=True, help="Number of widths") - parser.add_argument("--num-frames", type=int, required=True, help="Number of frames") - - # Training batch and model configuration - parser.add_argument("--train-batch-size", type=int, required=True, help="Training batch size") - parser.add_argument("--num-latent-t", type=int, required=True, help="Number of latent time steps") - parser.add_argument("--group-frame", action=StoreBoolean, help="Whether to group frames during training") - parser.add_argument("--group-resolution", - action=StoreBoolean, - help="Whether to group resolutions during training") - - # Model paths - parser.add_argument("--pretrained-model-name-or-path", - type=str, - required=True, - help="Path to pretrained model or model name") - parser.add_argument("--dit-model-name-or-path", - type=str, - required=False, - help="Path to DiT model or model name") - parser.add_argument("--cache-dir", type=str, help="Directory to cache models") - - # DMD model paths - separate paths for each network - parser.add_argument("--generator-model-path", - type=str, - help="Path to generator (student) model for DMD distillation") - parser.add_argument("--real-score-model-path", - type=str, - help="Path to real score (teacher) model for DMD distillation") - parser.add_argument("--fake-score-model-path", - type=str, - help="Path to fake score (critic) model for DMD distillation") - - # Diffusion settings - parser.add_argument("--ema-decay", type=float, default=0.999, help="EMA decay rate") - parser.add_argument("--ema-start-step", type=int, default=0, help="Step to start EMA") - parser.add_argument("--training-cfg-rate", type=float, help="Classifier-free guidance scale") - parser.add_argument("--precondition-outputs", - action=StoreBoolean, - help="Whether to precondition the outputs of the model") - - # Validation and logging - parser.add_argument("--validation-dataset-file", type=str, help="Path to unprocessed validation dataset") - parser.add_argument("--validation-preprocessed-path", type=str, help="Path to processed validation dataset") - parser.add_argument("--validation-sampling-steps", type=str, help="Validation sampling steps") - parser.add_argument("--validation-guidance-scale", type=str, help="Validation guidance scale") - parser.add_argument("--validation-steps", type=float, help="Number of validation steps") - parser.add_argument("--log-validation", action=StoreBoolean, help="Whether to log validation results") - parser.add_argument("--visualization-steps", type=int, help="Number of visualization steps") - parser.add_argument("--tracker-project-name", type=str, help="Project name for tracking") - parser.add_argument("--wandb-run-name", type=str, help="Run name for wandb") - parser.add_argument("--seed", type=int, default=42, help="Seed for deterministic training") - - # Output configuration - parser.add_argument("--output-dir", type=str, required=True, help="Output directory for checkpoints and logs") - parser.add_argument("--checkpoints-total-limit", type=int, help="Maximum number of checkpoints to keep") - parser.add_argument("--training-state-checkpointing-steps", - type=int, - help="Steps between training state checkpoints (for resuming training)") - parser.add_argument("--weight-only-checkpointing-steps", - type=int, - help="Steps between weight-only checkpoints (for inference)") - parser.add_argument("--resume-from-checkpoint", type=str, help="Path to checkpoint to resume from") - parser.add_argument("--logging-dir", type=str, help="Directory for logging") - - # Training configuration - parser.add_argument("--num-train-epochs", type=int, help="Number of training epochs") - parser.add_argument("--max-train-steps", type=int, help="Maximum number of training steps") - parser.add_argument("--gradient-accumulation-steps", type=int, help="Number of steps to accumulate gradients") - parser.add_argument("--learning-rate", type=float, required=True, help="Learning rate") - parser.add_argument("--scale-lr", action=StoreBoolean, help="Whether to scale learning rate") - parser.add_argument("--lr-scheduler", type=str, default="constant", help="Learning rate scheduler type") - parser.add_argument("--lr-warmup-steps", type=int, default=10, help="Number of warmup steps for learning rate") - parser.add_argument("--max-grad-norm", type=float, help="Maximum gradient norm") - parser.add_argument("--enable-gradient-checkpointing-type", - type=str, - choices=["full", "ops", "block_skip"], - default=None, - help="Gradient checkpointing type") - parser.add_argument("--selective-checkpointing", type=float, help="Selective checkpointing threshold") - parser.add_argument("--mixed-precision", type=str, help="Mixed precision training type") - parser.add_argument("--train-sp-batch-size", type=int, help="Training spatial parallelism batch size") - - parser.add_argument("--fsdp-sharding-strategy", type=str, help="FSDP sharding strategy") - - parser.add_argument( - "--weighting_scheme", - type=str, - default="uniform", - choices=["sigma_sqrt", "logit_normal", "mode", "cosmap", "uniform"], - ) - parser.add_argument( - "--logit_mean", - type=float, - default=0.0, - help="mean to use when using the `'logit_normal'` weighting scheme.", - ) - parser.add_argument( - "--logit_std", - type=float, - default=1.0, - help="std to use when using the `'logit_normal'` weighting scheme.", - ) - parser.add_argument( - "--mode_scale", - type=float, - default=1.29, - help="Scale of mode weighting scheme. Only effective when using the `'mode'` as the `weighting_scheme`.", - ) - - # Additional training parameters - parser.add_argument("--num-euler-timesteps", type=int, help="Number of Euler timesteps") - parser.add_argument("--lr-num-cycles", type=int, help="Number of learning rate cycles") - parser.add_argument("--lr-power", type=float, help="Learning rate power") - parser.add_argument("--min-lr-ratio", - type=float, - default=TrainingArgs.min_lr_ratio, - help="Minimum learning rate ratio for cosine_with_min_lr scheduler") - parser.add_argument("--not-apply-cfg-solver", action=StoreBoolean, help="Whether to not apply CFG solver") - parser.add_argument("--distill-cfg", type=float, help="Distillation CFG scale") - parser.add_argument("--scheduler-type", type=str, help="Scheduler type") - parser.add_argument("--linear-quadratic-threshold", type=float, help="Linear quadratic threshold") - parser.add_argument("--linear-range", type=float, help="Linear range") - parser.add_argument("--weight-decay", type=float, help="Weight decay") - parser.add_argument("--betas", - type=str, - default=TrainingArgs.betas, - help="Betas for optimizer (format: 'beta1,beta2')") - parser.add_argument("--use-ema", action=StoreBoolean, help="Whether to use EMA") - parser.add_argument("--multi-phased-distill-schedule", type=str, help="Multi-phased distillation schedule") - parser.add_argument("--pred-decay-weight", type=float, help="Prediction decay weight") - parser.add_argument("--pred-decay-type", type=str, help="Prediction decay type") - parser.add_argument("--hunyuan-teacher-disable-cfg", - action=StoreBoolean, - help="Whether to disable CFG for Hunyuan teacher") - parser.add_argument("--master-weight-type", type=str, help="Master weight type") - - # VSA parameters for training with dense to sparse adaption - parser.add_argument( - "--VSA-decay-rate", # decay rate, how much sparsity you want to decay each step - type=float, - default=TrainingArgs.VSA_decay_rate, - help="VSA decay rate") - parser.add_argument( - "--VSA-decay-interval-steps", # how many steps for training with current sparsity - type=int, - default=TrainingArgs.VSA_decay_interval_steps, - help="VSA decay interval steps") - parser.add_argument("--VSA-cache-tile-buf", - action=StoreBoolean, - default=TrainingArgs.VSA_cache_tile_buf, - help="Reuse the per-step padded VSA tile buffer across attention " - "layers during training. Off by default to avoid the activation-" - "checkpointing OOM (#1423); enable on memory-rich setups for the " - "per-step buffer-reuse speedup.") - parser.add_argument("--lora-training", action=StoreBoolean, help="Whether to use LoRA training") - parser.add_argument("--lora-rank", type=int, help="LoRA rank") - parser.add_argument("--lora-alpha", type=int, help="LoRA alpha") - parser.add_argument( - "--ltx2-first-frame-conditioning-p", - type=float, - default=TrainingArgs.ltx2_first_frame_conditioning_p, - help="Probability of conditioning on the first frame during LTX-2 training", - ) - - # V-MoBA parameters - parser.add_argument( - "--moba-config-path", - type=str, - default=None, - help="Path to a JSON file containing V-MoBA specific configurations.", - ) - - # Distillation arguments - parser.add_argument("--generator-update-interval", - type=int, - default=TrainingArgs.generator_update_interval, - help="Ratio of student updates to critic updates.") - parser.add_argument( - "--dfake-gen-update-ratio", - type=int, - default=TrainingArgs.dfake_gen_update_ratio, - help="Self-forcing: How often to train generator vs critic (train generator every N steps).") - parser.add_argument("--min-timestep-ratio", - type=float, - default=TrainingArgs.min_timestep_ratio, - help="Minimum step ratio") - parser.add_argument("--max-timestep-ratio", - type=float, - default=TrainingArgs.max_timestep_ratio, - help="Maximum step ratio") - parser.add_argument("--real-score-guidance-scale", - type=float, - default=TrainingArgs.real_score_guidance_scale, - help=("Teacher CFG scale for the real score in the DMD loss. Uses " - "the parameterization x_cond + w * (x_cond - x_uncond), so " - "w=0 -> cond, w=-1 -> uncond, and the relation to standard " - "CFG is w_standard = w + 1 (default 3.5 == standard 4.5).")) - parser.add_argument("--fake-score-learning-rate", - type=float, - default=TrainingArgs.fake_score_learning_rate, - help="Learning rate for fake score transformer") - parser.add_argument("--fake-score-betas", - type=str, - default=TrainingArgs.fake_score_betas, - help="Betas for fake score optimizer (format: 'beta1,beta2')") - parser.add_argument("--fake-score-lr-scheduler", - type=str, - default=TrainingArgs.fake_score_lr_scheduler, - help="Learning rate scheduler for fake score transformer") - parser.add_argument("--log-visualization", action=StoreBoolean, help="Whether to log visualization") - parser.add_argument("--simulate-generator-forward", - action=StoreBoolean, - help="Whether to simulate generator forward to match inference") - parser.add_argument("--warp-denoising-step", - action=StoreBoolean, - help="Whether to warp denoising step according to the scheduler time shift") - - # Self-forcing specific arguments - parser.add_argument("--num-frame-per-block", - type=int, - default=TrainingArgs.num_frame_per_block, - help="Number of frames per block for causal generation") - parser.add_argument("--independent-first-frame", - action=StoreBoolean, - help="Whether the first frame is independent in causal generation") - parser.add_argument("--enable-gradient-masking", - action=StoreBoolean, - help="Whether to enable frame-level gradient masking") - parser.add_argument("--gradient-mask-last-n-frames", - type=int, - default=TrainingArgs.gradient_mask_last_n_frames, - help="Number of last frames to enable gradients for") - parser.add_argument("--validate-cache-structure", - action=StoreBoolean, - help="Whether to validate KV cache structure (debug flag)") - parser.add_argument("--same-step-across-blocks", - action=StoreBoolean, - help="Whether to use the same exit timestep for all blocks") - parser.add_argument("--last-step-only", - action=StoreBoolean, - help="Whether to only use the last timestep for training") - parser.add_argument("--context-noise", - type=int, - default=TrainingArgs.context_noise, - help="Context noise level for cache updates") - - return parser - - -def parse_int_list(value: str) -> list[int]: - if not value: - return [] - return [int(x.strip()) for x in value.split(",")] diff --git a/fastvideo/pipelines/basic/lingbot_video/lingbot_video_pipeline.py b/fastvideo/pipelines/basic/lingbot_video/lingbot_video_pipeline.py index b6ca3620b..f54559425 100644 --- a/fastvideo/pipelines/basic/lingbot_video/lingbot_video_pipeline.py +++ b/fastvideo/pipelines/basic/lingbot_video/lingbot_video_pipeline.py @@ -33,8 +33,8 @@ class LingBotVideoPipeline(LoRAPipeline, ComposedPipelineBase): """Load the optional refiner DiT and the VAE encoder only when declared.""" model_index = self._load_config(self.model_path) required = list(type(self)._required_config_modules) - # The shared stage-2 refine switch: ``pipeline.preset_overrides.refine.enabled`` and the ``refine_enabled`` - # key resolve into ``pipeline.ltx2.refine.enabled``; ``None`` loads the refiner when the checkpoint has one. + # The shared stage-2 refine switch: ``pipeline.preset_overrides.refine.enabled`` resolves into + # ``pipeline.ltx2.refine.enabled``; ``None`` loads the refiner when the checkpoint has one. load_refiner = "transformer_2" in model_index and resolved_config.pipeline.ltx2.refine.enabled is not False if load_refiner: required.append("transformer_2") diff --git a/fastvideo/pipelines/composed_pipeline_base.py b/fastvideo/pipelines/composed_pipeline_base.py index ffdef8479..bc7cc132d 100644 --- a/fastvideo/pipelines/composed_pipeline_base.py +++ b/fastvideo/pipelines/composed_pipeline_base.py @@ -419,10 +419,6 @@ class ComposedPipelineBase(ABC): config/pretrained weights. """ if resolved_config.training_mode: - # Training keeps the DiT on the device. - if resolved_config.engine.offload.dit: - resolved_config = resolved_config.with_override("ComposedPipelineBase.from_pretrained:training", - {"engine.offload.dit": False}) # we hijack the precision to be the master weight type so that the # model is loaded with the correct precision. Subsequently we will # use FSDP2's MixedPrecisionPolicy to set the precision for the diff --git a/fastvideo/tests/api/config_snapshot.py b/fastvideo/tests/api/config_snapshot.py index 99c56f102..3f9b450e5 100644 --- a/fastvideo/tests/api/config_snapshot.py +++ b/fastvideo/tests/api/config_snapshot.py @@ -1,19 +1,19 @@ # SPDX-License-Identifier: Apache-2.0 """Snapshot cases for the final configuration objects, compared against golden JSON files. -Each case builds the configuration objects that runtime code reads (``FastVideoArgs`` with its ``PipelineConfig``, -and a ``SamplingParam`` where the case has a request) through one of the public entry paths: +Each case builds the configuration objects that runtime code reads through one of the public entry paths. A generator +case records the resolved config (``ResolvedGeneratorConfig.to_dict()``), its ``PipelineConfig`` and class, and the +resolution decisions; a request case records the ``SamplingParam`` and the request resolution. -- ``registry``: every registered model path, through ``FastVideoArgs.from_kwargs`` and ``SamplingParam.from_pretrained``. -- ``yaml``: every repository config file with a ``generator`` section, through ``load_generator_config_from_file``, - ``resolve_inference_config``, and ``generator_config_to_fastvideo_args``, with the resolution decisions; its ``request`` or ``default_request`` through the ``fastvideo generate`` and +- ``registry``: every registered model path, through ``resolve_inference_config`` and ``SamplingParam.from_pretrained``. +- ``yaml``: every repository config file with a ``generator`` section, through ``load_generator_config_from_file`` and + ``resolve_inference_config``; its ``request`` or ``default_request`` through the ``fastvideo generate`` and ``fastvideo serve`` loaders and ``request_to_sampling_param``. - ``kwargs``: ``VideoGenerator.from_pretrained`` keywords, through ``from_pretrained_kwargs_to_config`` and the same resolution. - ``config``: typed ``GeneratorConfig`` mappings, as ``VideoGenerator.from_config`` receives them, through the same resolution. -- ``cli``: argparse flags, through ``FastVideoArgs.add_cli_args`` and ``FastVideoArgs.from_cli_args``. -- ``environment``: environment variables that ``FastVideoArgs.__post_init__`` folds into fields. +- ``environment``: environment variables that resolution folds into typed fields. - ``request``: typed ``GenerationRequest`` values, through ``request_to_sampling_param``. Every case runs with all registered environment variables unset (except the ones an ``env`` case sets) and with model @@ -134,29 +134,22 @@ def to_jsonable(value: Any) -> Any: return _normalize_text(repr(value)) -def snapshot_fastvideo_args(resolved_config: Any) -> dict[str, Any]: - """FastVideoArgs fields, with its PipelineConfig as a separate top-level entry.""" - fields = { - field.name: to_jsonable(getattr(resolved_config, field.name)) - for field in dataclasses.fields(resolved_config) if field.name != "pipeline_config" - } +def snapshot_resolved_config(resolved_config: Any) -> dict[str, Any]: + """The resolved values, the ``PipelineConfig`` and its class, and the resolution decisions of a resolved config.""" pipeline_config = resolved_config.pipeline_config return { - "fastvideo_args": fields, + "resolved_config": to_jsonable(resolved_config.to_dict()), "pipeline_config_class": f"{type(pipeline_config).__module__}.{type(pipeline_config).__qualname__}", "pipeline_config": to_jsonable(pipeline_config), + "resolution_decisions": to_jsonable(resolved_config.decisions), } -def snapshot_resolved_fastvideo_args(generator_config: Any) -> dict[str, Any]: - """Resolve a GeneratorConfig the way VideoGenerator.from_config does, and record the resolution decisions.""" - from fastvideo.api.compat import generator_config_to_fastvideo_args +def snapshot_resolved_generator_config(generator_config: Any) -> dict[str, Any]: + """Resolve a GeneratorConfig or raw mapping the way VideoGenerator.from_config does, and snapshot the result.""" from fastvideo.api.inference_resolution import resolve_inference_config - resolved = resolve_inference_config(generator_config) - snapshot = snapshot_fastvideo_args(generator_config_to_fastvideo_args(resolved)) - snapshot["resolution_decisions"] = to_jsonable(resolved.decisions) - return snapshot + return snapshot_resolved_config(resolve_inference_config(generator_config)) def snapshot_sampling_param(sampling_param: Any) -> dict[str, Any]: @@ -220,18 +213,12 @@ def isolated_environment(env_values: dict[str, Any] | None = None) -> Iterator[N # --------------------------------------------------------------------------- -def _from_kwargs(**kwargs: Any) -> dict[str, Any]: - from fastvideo.fastvideo_args import FastVideoArgs - - return snapshot_fastvideo_args(FastVideoArgs.from_kwargs(**kwargs)) - - def _registry_case(model_path: str) -> Callable[[], dict[str, Any]]: def build() -> dict[str, Any]: from fastvideo.api.sampling_param import SamplingParam - snapshot = _from_kwargs(model_path=model_path) + snapshot = snapshot_resolved_generator_config({"model_path": model_path}) snapshot.update(snapshot_sampling_param(SamplingParam.from_pretrained(model_path))) return snapshot @@ -245,7 +232,7 @@ def _yaml_case(path: Path) -> Callable[[], dict[str, Any]]: from fastvideo.api.compat import load_generator_config_from_file generator_config = load_generator_config_from_file(path) - snapshot = snapshot_resolved_fastvideo_args(generator_config) + snapshot = snapshot_resolved_generator_config(generator_config) snapshot.update(snapshot_request(_yaml_request(path), generator_config.model_path)) return snapshot @@ -267,7 +254,7 @@ def _kwargs_case(model_path: str, kwargs: dict[str, Any]) -> Callable[[], dict[s def build() -> dict[str, Any]: from fastvideo.api.compat import from_pretrained_kwargs_to_config - return snapshot_resolved_fastvideo_args(from_pretrained_kwargs_to_config(model_path, kwargs)) + return snapshot_resolved_generator_config(from_pretrained_kwargs_to_config(model_path, kwargs)) return build @@ -277,29 +264,16 @@ def _config_case(raw: dict[str, Any]) -> Callable[[], dict[str, Any]]: def build() -> dict[str, Any]: from fastvideo.api.compat import normalize_generator_config - return snapshot_resolved_fastvideo_args(normalize_generator_config(raw)) + return snapshot_resolved_generator_config(normalize_generator_config(raw)) return build -def _cli_case(argv: list[str]) -> Callable[[], dict[str, Any]]: +def _env_case(env_values: dict[str, Any], raw: dict[str, Any]) -> Callable[[], dict[str, Any]]: + """A resolution of the raw generator mapping ``raw`` run with ``env_values`` set (applied by ``run_case``).""" def build() -> dict[str, Any]: - from fastvideo.fastvideo_args import FastVideoArgs - from fastvideo.utils import FlexibleArgumentParser - - parser = FlexibleArgumentParser() - FastVideoArgs.add_cli_args(parser) - return snapshot_fastvideo_args(FastVideoArgs.from_cli_args(parser.parse_args(argv))) - - return build - - -def _env_case(env_values: dict[str, Any], **kwargs: Any) -> Callable[[], dict[str, Any]]: - """A FastVideoArgs.from_kwargs case run with ``env_values`` set (applied by ``run_case``).""" - - def build() -> dict[str, Any]: - return _from_kwargs(**kwargs) + return snapshot_resolved_generator_config(raw) build.env_values = env_values # type: ignore[attr-defined] return build @@ -319,7 +293,7 @@ def _repository_config_files() -> list[Path]: """Every YAML file outside the tests that has a ``generator`` mapping at the top level. Files with ``runtime: mlx`` are skipped: ``fastvideo/entrypoints/openai/mlx_server.py`` reads them with its own - schema, and they never reach ``FastVideoArgs``. + schema, and they never reach ``resolve_inference_config``. """ files = [] for path in sorted(REPO_ROOT.rglob("*.y*ml")): @@ -344,7 +318,7 @@ def collect_cases() -> list[SnapshotCase]: SnapshotCase("yaml", path.relative_to(REPO_ROOT).as_posix(), _yaml_case(path)) for path in _repository_config_files() ] - # One case per kind of branch in from_pretrained_kwargs_to_config: flat names of typed fields and compile sub-keys. + # One case per kind of branch in from_pretrained_kwargs_to_config: keywords of typed fields and compile sub-keys. kwargs_cases = { "typed_offload_and_parallelism": (WAN_T2V, { "num_gpus": 2, @@ -370,8 +344,9 @@ def collect_cases() -> list[SnapshotCase]: cases += [ SnapshotCase("kwargs", name, _kwargs_case(model, kwargs)) for name, (model, kwargs) in kwargs_cases.items() ] - # Typed configs for the settings that only from_config accepts: typed fields, keys left in - # pipeline.experimental, LTX-2 refine and VAE tile fields, and a pipeline config JSON path. + # Typed configs for the settings that only from_config accepts: typed fields, a model-only PipelineConfig + # attribute and a key that code reads by name in pipeline.experimental, LTX-2 refine and VAE tile fields, and a + # pipeline config JSON path. pipeline_json = str(REPO_ROOT / "fastvideo/configs/fasthunyuan_t2v.json") config_cases = { "attention_precision_and_flow_shift": { @@ -389,13 +364,30 @@ def collect_cases() -> list[SnapshotCase]: "flow_shift": 5.0 }, }, - "keys_without_typed_fields": { + "master_port_refine_enabled_boundary_ratio": { + "model_path": WAN_T2V, + "engine": { + "parallelism": { + "master_port": 29600 + } + }, + "pipeline": { + "ltx2": { + "refine": { + "enabled": True + } + }, + "boundary_ratio": 0.5 + }, + }, + "experimental_keys": { "model_path": WAN_T2V, "pipeline": { "experimental": { - "master_port": 29600, - "refine_enabled": True, - "boundary_ratio": 0.5 + "flow_shift_sr": 2.0, + "ray_runtime_env": { + "pip": ["probe"] + } } }, }, @@ -430,9 +422,7 @@ def collect_cases() -> list[SnapshotCase]: "boundary_ratio": { "model_path": WAN22_T2V, "pipeline": { - "experimental": { - "boundary_ratio": 0.8 - } + "boundary_ratio": 0.8 }, }, "vae_tiling_typed": { @@ -452,27 +442,7 @@ def collect_cases() -> list[SnapshotCase]: }, } cases += [SnapshotCase("config", name, _config_case(raw)) for name, raw in config_cases.items()] - # argparse defaults differ from the dataclass defaults, so model_path_only is the CLI baseline. - cli_cases = { - "model_path_only": ["--model-path", WAN_T2V], - "offload_and_parallelism": [ - "--model-path", WAN_T2V, "--num-gpus", "2", "--sp-size", "2", "--dit-cpu-offload", "true", - "--vae-cpu-offload", "false" - ], - "attention_backend_and_disable_autocast": - ["--model-path", WAN_T2V, "--attention-backend", "TORCH_SDPA", "--disable-autocast"], - "pipeline_config_flags": [ - "--model-path", WAN_T2V, "--flow-shift", "5.0", "--dit-precision", "fp32", "--embedded-cfg-scale", "4.5", - "--vae-tiling", "false", "--vae-sp", "false" - ], - "vae_config_flags": [ - "--model-path", WAN_T2V, "--vae-config.load-encoder", "false", "--vae-config.use-tiling", "true", - "--vae-config.tile-sample-min-height", "128" - ], - "dit_config_flags": ["--model-path", WAN_T2V, "--dit-config.prefix", "Probe"], - } - cases += [SnapshotCase("cli", name, _cli_case(argv)) for name, argv in cli_cases.items()] - # Environment variables that FastVideoArgs.__post_init__ folds into fields. + # Environment variables that resolution folds into typed fields. env_cases = { "attention_backend": { "FASTVIDEO_ATTENTION_BACKEND": "TORCH_SDPA" @@ -490,14 +460,20 @@ def collect_cases() -> list[SnapshotCase]: }, } cases += [ - SnapshotCase("environment", name, _env_case(env_values, model_path=WAN_T2V)) + SnapshotCase("environment", name, _env_case(env_values, {"model_path": WAN_T2V})) for name, env_values in env_cases.items() ] cases.append( - SnapshotCase("environment", "explicit_argument_wins_over_attention_backend", - _env_case({"FASTVIDEO_ATTENTION_BACKEND": "TORCH_SDPA"}, - model_path=WAN_T2V, - attention_backend="FLASH_ATTN"))) + SnapshotCase( + "environment", "explicit_argument_wins_over_attention_backend", + _env_case({"FASTVIDEO_ATTENTION_BACKEND": "TORCH_SDPA"}, { + "model_path": WAN_T2V, + "engine": { + "attention": { + "backend": "FLASH_ATTN" + } + } + }))) # Requests cover sampling fields, LTX-2 stage overrides, extensions, and output flags. request_cases = { "sampling_values": (WAN_T2V, { diff --git a/fastvideo/tests/api/config_snapshot_goldens/cli/attention_backend_and_disable_autocast.json b/fastvideo/tests/api/config_snapshot_goldens/cli/attention_backend_and_disable_autocast.json deleted file mode 100644 index f456025dd..000000000 --- a/fastvideo/tests/api/config_snapshot_goldens/cli/attention_backend_and_disable_autocast.json +++ /dev/null @@ -1,375 +0,0 @@ -{ - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": "TORCH_SDPA", - "boundary_ratio": 0.875, - "disable_autocast": true, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": false, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": null, - "init_weights_from_safetensors_2": null, - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, - "pipeline_config": { - "boundary_ratio": null, - "disable_autocast": true, - "dit_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 3, - 1, - 2, - 7, - 10, - 4, - 5, - 6, - 11, - 12 - ], - "added_kv_proj_dim": null, - "attention_head_dim": 128, - "boundary_ratio": null, - "cast_prompt_embeds_to_dit_dtype": false, - "cross_attn_norm": true, - "eps": 1e-06, - "exclude_lora_layers": [ - "embedder" - ], - "ffn_dim": 13824, - "freq_dim": 256, - "hidden_size": 5120, - "image_dim": null, - "in_channels": 16, - "local_attn_size": -1, - "num_attention_heads": 40, - "num_channels_latents": 16, - "num_frames_per_block": 3, - "num_layers": 40, - "out_channels": 16, - "patch_size": [ - 1, - 2, - 2 - ], - "pos_embed_seq_len": null, - "qk_norm": "rms_norm_across_heads", - "r_embedder": false, - "r_embedder_deltatime_type": "r", - "r_embedder_fusion": "additive", - "r_embedder_gate_value": 0.25, - "rope_cache_policy": "absolute", - "rope_max_seq_len": 1024, - "sink_size": 0, - "sliding_window_num_frames": 21, - "stacked_params_mapping": [], - "text_dim": 4096 - }, - "prefix": "Wan", - "quant_config": null - }, - "dit_precision": "bf16", - "dmd_denoising_steps": null, - "embedded_cfg_scale": 6.0, - "flow_shift": 3.0, - "flow_shift_sr": null, - "image_encoder_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "output_hidden_states": false, - "stacked_params_mapping": [], - "use_return_dict": true - }, - "lora_config": null, - "prefix": "", - "quant_config": null - }, - "image_encoder_configs": null, - "image_encoder_precision": "fp32", - "image_encoder_precisions": null, - "is_causal": false, - "lucy_edit_task": false, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "pipeline_config_path": null, - "postprocess_text_funcs": [ - "fastvideo.models.wan.pipeline_config.t5_postprocess_text" - ], - "precision": "bf16", - "preprocess_text_funcs": [ - "fastvideo.configs.pipelines.base.preprocess_text" - ], - "scheduler_step_in_fp32": false, - "text_encoder_configs": [ - { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "classifier_dropout": 0.0, - "d_ff": 2048, - "d_kv": 64, - "d_model": 512, - "decoder_start_token_id": 0, - "dense_act_fn": "relu", - "dropout_rate": 0.1, - "dtype": null, - "eos_token_id": 1, - "feed_forward_proj": "relu", - "gradient_checkpointing": false, - "hidden_size": 512, - "hidden_state_skip_layer": 0, - "initializer_factor": 1.0, - "is_encoder_decoder": true, - "is_gated_act": false, - "layer_norm_epsilon": 1e-06, - "n_positions": 512, - "num_attention_heads": 0, - "num_decoder_layers": null, - "num_heads": 8, - "num_hidden_layers": 0, - "num_layers": 6, - "output_hidden_states": false, - "output_past": true, - "pad_token_id": 0, - "relative_attention_max_distance": 128, - "relative_attention_num_buckets": 32, - "require_processor": false, - "scalable_attention": true, - "stacked_params_mapping": [ - [ - ".qkv_proj", - ".q", - "q" - ], - [ - ".qkv_proj", - ".k", - "k" - ], - [ - ".qkv_proj", - ".v", - "v" - ] - ], - "task_specific_params": null, - "text_len": 512, - "tie_word_embeddings": false, - "tokenizer_kwargs": { - "add_special_tokens": true, - "max_length": 512, - "return_attention_mask": true, - "return_tensors": "pt", - "truncation": true - }, - "use_cache": true, - "use_return_dict": true, - "vocab_size": 32128 - }, - "chat_template_enable_thinking": false, - "is_chat_model": false, - "lora_config": null, - "prefix": "t5", - "quant_config": null, - "treat_empty_as_dot": false - } - ], - "text_encoder_precisions": [ - "fp32" - ], - "ti2v_task": false, - "upsampler_config": { - "_resolved_attention_backend": null, - "arch_config": { - "stacked_params_mapping": [] - } - }, - "upsampler_precision": "fp32", - "vae_config": { - "_resolved_attention_backend": null, - "arch_config": { - "attn_scales": [], - "base_dim": 96, - "clip_output": true, - "decoder_base_dim": null, - "dim_mult": [ - 1, - 2, - 4, - 4 - ], - "dropout": 0.0, - "in_channels": 3, - "is_residual": false, - "latents_mean": [ - -0.7571, - -0.7089, - -0.9113, - 0.1075, - -0.1745, - 0.9653, - -0.1517, - 1.5508, - 0.4134, - -0.0715, - 0.5517, - -0.3632, - -0.1922, - -0.9497, - 0.2503, - -0.2921 - ], - "latents_std": [ - 2.8184, - 1.4541, - 2.3275, - 2.6558, - 1.2196, - 1.7708, - 2.6052, - 2.0743, - 3.2687, - 2.1526, - 2.8652, - 1.5579, - 1.6382, - 1.1253, - 2.8251, - 1.916 - ], - "num_res_blocks": 2, - "out_channels": 3, - "patch_size": null, - "scale_factor_spatial": 8, - "scale_factor_temporal": 4, - "scaling_factor": "", - "spatial_compression_ratio": 8, - "stacked_params_mapping": [], - "temperal_downsample": [ - false, - true, - true - ], - "temporal_compression_ratio": 4, - "z_dim": 16 - }, - "blend_num_frames": 8, - "load_decoder": true, - "load_encoder": false, - "tile_sample_min_height": 256, - "tile_sample_min_num_frames": 16, - "tile_sample_min_width": 256, - "tile_sample_stride_height": 192, - "tile_sample_stride_num_frames": 12, - "tile_sample_stride_width": 192, - "use_feature_cache": true, - "use_light_vae": false, - "use_parallel_tiling": false, - "use_temporal_scaling_frames": true, - "use_temporal_tiling": false, - "use_tiling": false - }, - "vae_decode_precision": "bf16", - "vae_precision": "fp32", - "vae_sp": false, - "vae_tiling": false, - "warp_denoising_step": true - }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" -} diff --git a/fastvideo/tests/api/config_snapshot_goldens/cli/dit_config_flags.json b/fastvideo/tests/api/config_snapshot_goldens/cli/dit_config_flags.json deleted file mode 100644 index 186d96fc3..000000000 --- a/fastvideo/tests/api/config_snapshot_goldens/cli/dit_config_flags.json +++ /dev/null @@ -1,375 +0,0 @@ -{ - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": false, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": null, - "init_weights_from_safetensors_2": null, - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, - "pipeline_config": { - "boundary_ratio": null, - "disable_autocast": false, - "dit_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 3, - 1, - 2, - 7, - 10, - 4, - 5, - 6, - 11, - 12 - ], - "added_kv_proj_dim": null, - "attention_head_dim": 128, - "boundary_ratio": null, - "cast_prompt_embeds_to_dit_dtype": false, - "cross_attn_norm": true, - "eps": 1e-06, - "exclude_lora_layers": [ - "embedder" - ], - "ffn_dim": 13824, - "freq_dim": 256, - "hidden_size": 5120, - "image_dim": null, - "in_channels": 16, - "local_attn_size": -1, - "num_attention_heads": 40, - "num_channels_latents": 16, - "num_frames_per_block": 3, - "num_layers": 40, - "out_channels": 16, - "patch_size": [ - 1, - 2, - 2 - ], - "pos_embed_seq_len": null, - "qk_norm": "rms_norm_across_heads", - "r_embedder": false, - "r_embedder_deltatime_type": "r", - "r_embedder_fusion": "additive", - "r_embedder_gate_value": 0.25, - "rope_cache_policy": "absolute", - "rope_max_seq_len": 1024, - "sink_size": 0, - "sliding_window_num_frames": 21, - "stacked_params_mapping": [], - "text_dim": 4096 - }, - "prefix": "Probe", - "quant_config": null - }, - "dit_precision": "bf16", - "dmd_denoising_steps": null, - "embedded_cfg_scale": 6.0, - "flow_shift": 3.0, - "flow_shift_sr": null, - "image_encoder_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "output_hidden_states": false, - "stacked_params_mapping": [], - "use_return_dict": true - }, - "lora_config": null, - "prefix": "", - "quant_config": null - }, - "image_encoder_configs": null, - "image_encoder_precision": "fp32", - "image_encoder_precisions": null, - "is_causal": false, - "lucy_edit_task": false, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "pipeline_config_path": null, - "postprocess_text_funcs": [ - "fastvideo.models.wan.pipeline_config.t5_postprocess_text" - ], - "precision": "bf16", - "preprocess_text_funcs": [ - "fastvideo.configs.pipelines.base.preprocess_text" - ], - "scheduler_step_in_fp32": false, - "text_encoder_configs": [ - { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "classifier_dropout": 0.0, - "d_ff": 2048, - "d_kv": 64, - "d_model": 512, - "decoder_start_token_id": 0, - "dense_act_fn": "relu", - "dropout_rate": 0.1, - "dtype": null, - "eos_token_id": 1, - "feed_forward_proj": "relu", - "gradient_checkpointing": false, - "hidden_size": 512, - "hidden_state_skip_layer": 0, - "initializer_factor": 1.0, - "is_encoder_decoder": true, - "is_gated_act": false, - "layer_norm_epsilon": 1e-06, - "n_positions": 512, - "num_attention_heads": 0, - "num_decoder_layers": null, - "num_heads": 8, - "num_hidden_layers": 0, - "num_layers": 6, - "output_hidden_states": false, - "output_past": true, - "pad_token_id": 0, - "relative_attention_max_distance": 128, - "relative_attention_num_buckets": 32, - "require_processor": false, - "scalable_attention": true, - "stacked_params_mapping": [ - [ - ".qkv_proj", - ".q", - "q" - ], - [ - ".qkv_proj", - ".k", - "k" - ], - [ - ".qkv_proj", - ".v", - "v" - ] - ], - "task_specific_params": null, - "text_len": 512, - "tie_word_embeddings": false, - "tokenizer_kwargs": { - "add_special_tokens": true, - "max_length": 512, - "return_attention_mask": true, - "return_tensors": "pt", - "truncation": true - }, - "use_cache": true, - "use_return_dict": true, - "vocab_size": 32128 - }, - "chat_template_enable_thinking": false, - "is_chat_model": false, - "lora_config": null, - "prefix": "t5", - "quant_config": null, - "treat_empty_as_dot": false - } - ], - "text_encoder_precisions": [ - "fp32" - ], - "ti2v_task": false, - "upsampler_config": { - "_resolved_attention_backend": null, - "arch_config": { - "stacked_params_mapping": [] - } - }, - "upsampler_precision": "fp32", - "vae_config": { - "_resolved_attention_backend": null, - "arch_config": { - "attn_scales": [], - "base_dim": 96, - "clip_output": true, - "decoder_base_dim": null, - "dim_mult": [ - 1, - 2, - 4, - 4 - ], - "dropout": 0.0, - "in_channels": 3, - "is_residual": false, - "latents_mean": [ - -0.7571, - -0.7089, - -0.9113, - 0.1075, - -0.1745, - 0.9653, - -0.1517, - 1.5508, - 0.4134, - -0.0715, - 0.5517, - -0.3632, - -0.1922, - -0.9497, - 0.2503, - -0.2921 - ], - "latents_std": [ - 2.8184, - 1.4541, - 2.3275, - 2.6558, - 1.2196, - 1.7708, - 2.6052, - 2.0743, - 3.2687, - 2.1526, - 2.8652, - 1.5579, - 1.6382, - 1.1253, - 2.8251, - 1.916 - ], - "num_res_blocks": 2, - "out_channels": 3, - "patch_size": null, - "scale_factor_spatial": 8, - "scale_factor_temporal": 4, - "scaling_factor": "", - "spatial_compression_ratio": 8, - "stacked_params_mapping": [], - "temperal_downsample": [ - false, - true, - true - ], - "temporal_compression_ratio": 4, - "z_dim": 16 - }, - "blend_num_frames": 8, - "load_decoder": true, - "load_encoder": false, - "tile_sample_min_height": 256, - "tile_sample_min_num_frames": 16, - "tile_sample_min_width": 256, - "tile_sample_stride_height": 192, - "tile_sample_stride_num_frames": 12, - "tile_sample_stride_width": 192, - "use_feature_cache": true, - "use_light_vae": false, - "use_parallel_tiling": false, - "use_temporal_scaling_frames": true, - "use_temporal_tiling": false, - "use_tiling": false - }, - "vae_decode_precision": "bf16", - "vae_precision": "fp32", - "vae_sp": false, - "vae_tiling": false, - "warp_denoising_step": true - }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" -} diff --git a/fastvideo/tests/api/config_snapshot_goldens/cli/offload_and_parallelism.json b/fastvideo/tests/api/config_snapshot_goldens/cli/offload_and_parallelism.json deleted file mode 100644 index 365424f2a..000000000 --- a/fastvideo/tests/api/config_snapshot_goldens/cli/offload_and_parallelism.json +++ /dev/null @@ -1,375 +0,0 @@ -{ - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 2, - "image_encoder_cpu_offload": false, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": null, - "init_weights_from_safetensors_2": null, - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 2, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 2, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, - "pipeline_config": { - "boundary_ratio": null, - "disable_autocast": false, - "dit_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 3, - 1, - 2, - 7, - 10, - 4, - 5, - 6, - 11, - 12 - ], - "added_kv_proj_dim": null, - "attention_head_dim": 128, - "boundary_ratio": null, - "cast_prompt_embeds_to_dit_dtype": false, - "cross_attn_norm": true, - "eps": 1e-06, - "exclude_lora_layers": [ - "embedder" - ], - "ffn_dim": 13824, - "freq_dim": 256, - "hidden_size": 5120, - "image_dim": null, - "in_channels": 16, - "local_attn_size": -1, - "num_attention_heads": 40, - "num_channels_latents": 16, - "num_frames_per_block": 3, - "num_layers": 40, - "out_channels": 16, - "patch_size": [ - 1, - 2, - 2 - ], - "pos_embed_seq_len": null, - "qk_norm": "rms_norm_across_heads", - "r_embedder": false, - "r_embedder_deltatime_type": "r", - "r_embedder_fusion": "additive", - "r_embedder_gate_value": 0.25, - "rope_cache_policy": "absolute", - "rope_max_seq_len": 1024, - "sink_size": 0, - "sliding_window_num_frames": 21, - "stacked_params_mapping": [], - "text_dim": 4096 - }, - "prefix": "Wan", - "quant_config": null - }, - "dit_precision": "bf16", - "dmd_denoising_steps": null, - "embedded_cfg_scale": 6.0, - "flow_shift": 3.0, - "flow_shift_sr": null, - "image_encoder_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "output_hidden_states": false, - "stacked_params_mapping": [], - "use_return_dict": true - }, - "lora_config": null, - "prefix": "", - "quant_config": null - }, - "image_encoder_configs": null, - "image_encoder_precision": "fp32", - "image_encoder_precisions": null, - "is_causal": false, - "lucy_edit_task": false, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "pipeline_config_path": null, - "postprocess_text_funcs": [ - "fastvideo.models.wan.pipeline_config.t5_postprocess_text" - ], - "precision": "bf16", - "preprocess_text_funcs": [ - "fastvideo.configs.pipelines.base.preprocess_text" - ], - "scheduler_step_in_fp32": false, - "text_encoder_configs": [ - { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "classifier_dropout": 0.0, - "d_ff": 2048, - "d_kv": 64, - "d_model": 512, - "decoder_start_token_id": 0, - "dense_act_fn": "relu", - "dropout_rate": 0.1, - "dtype": null, - "eos_token_id": 1, - "feed_forward_proj": "relu", - "gradient_checkpointing": false, - "hidden_size": 512, - "hidden_state_skip_layer": 0, - "initializer_factor": 1.0, - "is_encoder_decoder": true, - "is_gated_act": false, - "layer_norm_epsilon": 1e-06, - "n_positions": 512, - "num_attention_heads": 0, - "num_decoder_layers": null, - "num_heads": 8, - "num_hidden_layers": 0, - "num_layers": 6, - "output_hidden_states": false, - "output_past": true, - "pad_token_id": 0, - "relative_attention_max_distance": 128, - "relative_attention_num_buckets": 32, - "require_processor": false, - "scalable_attention": true, - "stacked_params_mapping": [ - [ - ".qkv_proj", - ".q", - "q" - ], - [ - ".qkv_proj", - ".k", - "k" - ], - [ - ".qkv_proj", - ".v", - "v" - ] - ], - "task_specific_params": null, - "text_len": 512, - "tie_word_embeddings": false, - "tokenizer_kwargs": { - "add_special_tokens": true, - "max_length": 512, - "return_attention_mask": true, - "return_tensors": "pt", - "truncation": true - }, - "use_cache": true, - "use_return_dict": true, - "vocab_size": 32128 - }, - "chat_template_enable_thinking": false, - "is_chat_model": false, - "lora_config": null, - "prefix": "t5", - "quant_config": null, - "treat_empty_as_dot": false - } - ], - "text_encoder_precisions": [ - "fp32" - ], - "ti2v_task": false, - "upsampler_config": { - "_resolved_attention_backend": null, - "arch_config": { - "stacked_params_mapping": [] - } - }, - "upsampler_precision": "fp32", - "vae_config": { - "_resolved_attention_backend": null, - "arch_config": { - "attn_scales": [], - "base_dim": 96, - "clip_output": true, - "decoder_base_dim": null, - "dim_mult": [ - 1, - 2, - 4, - 4 - ], - "dropout": 0.0, - "in_channels": 3, - "is_residual": false, - "latents_mean": [ - -0.7571, - -0.7089, - -0.9113, - 0.1075, - -0.1745, - 0.9653, - -0.1517, - 1.5508, - 0.4134, - -0.0715, - 0.5517, - -0.3632, - -0.1922, - -0.9497, - 0.2503, - -0.2921 - ], - "latents_std": [ - 2.8184, - 1.4541, - 2.3275, - 2.6558, - 1.2196, - 1.7708, - 2.6052, - 2.0743, - 3.2687, - 2.1526, - 2.8652, - 1.5579, - 1.6382, - 1.1253, - 2.8251, - 1.916 - ], - "num_res_blocks": 2, - "out_channels": 3, - "patch_size": null, - "scale_factor_spatial": 8, - "scale_factor_temporal": 4, - "scaling_factor": "", - "spatial_compression_ratio": 8, - "stacked_params_mapping": [], - "temperal_downsample": [ - false, - true, - true - ], - "temporal_compression_ratio": 4, - "z_dim": 16 - }, - "blend_num_frames": 8, - "load_decoder": true, - "load_encoder": false, - "tile_sample_min_height": 256, - "tile_sample_min_num_frames": 16, - "tile_sample_min_width": 256, - "tile_sample_stride_height": 192, - "tile_sample_stride_num_frames": 12, - "tile_sample_stride_width": 192, - "use_feature_cache": true, - "use_light_vae": false, - "use_parallel_tiling": false, - "use_temporal_scaling_frames": true, - "use_temporal_tiling": false, - "use_tiling": false - }, - "vae_decode_precision": "bf16", - "vae_precision": "fp32", - "vae_sp": false, - "vae_tiling": false, - "warp_denoising_step": true - }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" -} diff --git a/fastvideo/tests/api/config_snapshot_goldens/cli/pipeline_config_flags.json b/fastvideo/tests/api/config_snapshot_goldens/cli/pipeline_config_flags.json deleted file mode 100644 index 5fdda2010..000000000 --- a/fastvideo/tests/api/config_snapshot_goldens/cli/pipeline_config_flags.json +++ /dev/null @@ -1,375 +0,0 @@ -{ - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": false, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": null, - "init_weights_from_safetensors_2": null, - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, - "pipeline_config": { - "boundary_ratio": null, - "disable_autocast": false, - "dit_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 3, - 1, - 2, - 7, - 10, - 4, - 5, - 6, - 11, - 12 - ], - "added_kv_proj_dim": null, - "attention_head_dim": 128, - "boundary_ratio": null, - "cast_prompt_embeds_to_dit_dtype": false, - "cross_attn_norm": true, - "eps": 1e-06, - "exclude_lora_layers": [ - "embedder" - ], - "ffn_dim": 13824, - "freq_dim": 256, - "hidden_size": 5120, - "image_dim": null, - "in_channels": 16, - "local_attn_size": -1, - "num_attention_heads": 40, - "num_channels_latents": 16, - "num_frames_per_block": 3, - "num_layers": 40, - "out_channels": 16, - "patch_size": [ - 1, - 2, - 2 - ], - "pos_embed_seq_len": null, - "qk_norm": "rms_norm_across_heads", - "r_embedder": false, - "r_embedder_deltatime_type": "r", - "r_embedder_fusion": "additive", - "r_embedder_gate_value": 0.25, - "rope_cache_policy": "absolute", - "rope_max_seq_len": 1024, - "sink_size": 0, - "sliding_window_num_frames": 21, - "stacked_params_mapping": [], - "text_dim": 4096 - }, - "prefix": "Wan", - "quant_config": null - }, - "dit_precision": "fp32", - "dmd_denoising_steps": null, - "embedded_cfg_scale": 4.5, - "flow_shift": 5.0, - "flow_shift_sr": null, - "image_encoder_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "output_hidden_states": false, - "stacked_params_mapping": [], - "use_return_dict": true - }, - "lora_config": null, - "prefix": "", - "quant_config": null - }, - "image_encoder_configs": null, - "image_encoder_precision": "fp32", - "image_encoder_precisions": null, - "is_causal": false, - "lucy_edit_task": false, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "pipeline_config_path": null, - "postprocess_text_funcs": [ - "fastvideo.models.wan.pipeline_config.t5_postprocess_text" - ], - "precision": "bf16", - "preprocess_text_funcs": [ - "fastvideo.configs.pipelines.base.preprocess_text" - ], - "scheduler_step_in_fp32": false, - "text_encoder_configs": [ - { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "classifier_dropout": 0.0, - "d_ff": 2048, - "d_kv": 64, - "d_model": 512, - "decoder_start_token_id": 0, - "dense_act_fn": "relu", - "dropout_rate": 0.1, - "dtype": null, - "eos_token_id": 1, - "feed_forward_proj": "relu", - "gradient_checkpointing": false, - "hidden_size": 512, - "hidden_state_skip_layer": 0, - "initializer_factor": 1.0, - "is_encoder_decoder": true, - "is_gated_act": false, - "layer_norm_epsilon": 1e-06, - "n_positions": 512, - "num_attention_heads": 0, - "num_decoder_layers": null, - "num_heads": 8, - "num_hidden_layers": 0, - "num_layers": 6, - "output_hidden_states": false, - "output_past": true, - "pad_token_id": 0, - "relative_attention_max_distance": 128, - "relative_attention_num_buckets": 32, - "require_processor": false, - "scalable_attention": true, - "stacked_params_mapping": [ - [ - ".qkv_proj", - ".q", - "q" - ], - [ - ".qkv_proj", - ".k", - "k" - ], - [ - ".qkv_proj", - ".v", - "v" - ] - ], - "task_specific_params": null, - "text_len": 512, - "tie_word_embeddings": false, - "tokenizer_kwargs": { - "add_special_tokens": true, - "max_length": 512, - "return_attention_mask": true, - "return_tensors": "pt", - "truncation": true - }, - "use_cache": true, - "use_return_dict": true, - "vocab_size": 32128 - }, - "chat_template_enable_thinking": false, - "is_chat_model": false, - "lora_config": null, - "prefix": "t5", - "quant_config": null, - "treat_empty_as_dot": false - } - ], - "text_encoder_precisions": [ - "fp32" - ], - "ti2v_task": false, - "upsampler_config": { - "_resolved_attention_backend": null, - "arch_config": { - "stacked_params_mapping": [] - } - }, - "upsampler_precision": "fp32", - "vae_config": { - "_resolved_attention_backend": null, - "arch_config": { - "attn_scales": [], - "base_dim": 96, - "clip_output": true, - "decoder_base_dim": null, - "dim_mult": [ - 1, - 2, - 4, - 4 - ], - "dropout": 0.0, - "in_channels": 3, - "is_residual": false, - "latents_mean": [ - -0.7571, - -0.7089, - -0.9113, - 0.1075, - -0.1745, - 0.9653, - -0.1517, - 1.5508, - 0.4134, - -0.0715, - 0.5517, - -0.3632, - -0.1922, - -0.9497, - 0.2503, - -0.2921 - ], - "latents_std": [ - 2.8184, - 1.4541, - 2.3275, - 2.6558, - 1.2196, - 1.7708, - 2.6052, - 2.0743, - 3.2687, - 2.1526, - 2.8652, - 1.5579, - 1.6382, - 1.1253, - 2.8251, - 1.916 - ], - "num_res_blocks": 2, - "out_channels": 3, - "patch_size": null, - "scale_factor_spatial": 8, - "scale_factor_temporal": 4, - "scaling_factor": "", - "spatial_compression_ratio": 8, - "stacked_params_mapping": [], - "temperal_downsample": [ - false, - true, - true - ], - "temporal_compression_ratio": 4, - "z_dim": 16 - }, - "blend_num_frames": 8, - "load_decoder": true, - "load_encoder": false, - "tile_sample_min_height": 256, - "tile_sample_min_num_frames": 16, - "tile_sample_min_width": 256, - "tile_sample_stride_height": 192, - "tile_sample_stride_num_frames": 12, - "tile_sample_stride_width": 192, - "use_feature_cache": true, - "use_light_vae": false, - "use_parallel_tiling": false, - "use_temporal_scaling_frames": true, - "use_temporal_tiling": false, - "use_tiling": false - }, - "vae_decode_precision": "bf16", - "vae_precision": "fp32", - "vae_sp": false, - "vae_tiling": false, - "warp_denoising_step": true - }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" -} diff --git a/fastvideo/tests/api/config_snapshot_goldens/cli/vae_config_flags.json b/fastvideo/tests/api/config_snapshot_goldens/cli/vae_config_flags.json deleted file mode 100644 index 0a9d7bcbc..000000000 --- a/fastvideo/tests/api/config_snapshot_goldens/cli/vae_config_flags.json +++ /dev/null @@ -1,375 +0,0 @@ -{ - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": false, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": null, - "init_weights_from_safetensors_2": null, - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, - "pipeline_config": { - "boundary_ratio": null, - "disable_autocast": false, - "dit_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 3, - 1, - 2, - 7, - 10, - 4, - 5, - 6, - 11, - 12 - ], - "added_kv_proj_dim": null, - "attention_head_dim": 128, - "boundary_ratio": null, - "cast_prompt_embeds_to_dit_dtype": false, - "cross_attn_norm": true, - "eps": 1e-06, - "exclude_lora_layers": [ - "embedder" - ], - "ffn_dim": 13824, - "freq_dim": 256, - "hidden_size": 5120, - "image_dim": null, - "in_channels": 16, - "local_attn_size": -1, - "num_attention_heads": 40, - "num_channels_latents": 16, - "num_frames_per_block": 3, - "num_layers": 40, - "out_channels": 16, - "patch_size": [ - 1, - 2, - 2 - ], - "pos_embed_seq_len": null, - "qk_norm": "rms_norm_across_heads", - "r_embedder": false, - "r_embedder_deltatime_type": "r", - "r_embedder_fusion": "additive", - "r_embedder_gate_value": 0.25, - "rope_cache_policy": "absolute", - "rope_max_seq_len": 1024, - "sink_size": 0, - "sliding_window_num_frames": 21, - "stacked_params_mapping": [], - "text_dim": 4096 - }, - "prefix": "Wan", - "quant_config": null - }, - "dit_precision": "bf16", - "dmd_denoising_steps": null, - "embedded_cfg_scale": 6.0, - "flow_shift": 3.0, - "flow_shift_sr": null, - "image_encoder_config": { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "output_hidden_states": false, - "stacked_params_mapping": [], - "use_return_dict": true - }, - "lora_config": null, - "prefix": "", - "quant_config": null - }, - "image_encoder_configs": null, - "image_encoder_precision": "fp32", - "image_encoder_precisions": null, - "is_causal": false, - "lucy_edit_task": false, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "pipeline_config_path": null, - "postprocess_text_funcs": [ - "fastvideo.models.wan.pipeline_config.t5_postprocess_text" - ], - "precision": "bf16", - "preprocess_text_funcs": [ - "fastvideo.configs.pipelines.base.preprocess_text" - ], - "scheduler_step_in_fp32": false, - "text_encoder_configs": [ - { - "_resolved_attention_backend": null, - "arch_config": { - "_supported_attention_backends": [ - 1, - 2 - ], - "architectures": [], - "classifier_dropout": 0.0, - "d_ff": 2048, - "d_kv": 64, - "d_model": 512, - "decoder_start_token_id": 0, - "dense_act_fn": "relu", - "dropout_rate": 0.1, - "dtype": null, - "eos_token_id": 1, - "feed_forward_proj": "relu", - "gradient_checkpointing": false, - "hidden_size": 512, - "hidden_state_skip_layer": 0, - "initializer_factor": 1.0, - "is_encoder_decoder": true, - "is_gated_act": false, - "layer_norm_epsilon": 1e-06, - "n_positions": 512, - "num_attention_heads": 0, - "num_decoder_layers": null, - "num_heads": 8, - "num_hidden_layers": 0, - "num_layers": 6, - "output_hidden_states": false, - "output_past": true, - "pad_token_id": 0, - "relative_attention_max_distance": 128, - "relative_attention_num_buckets": 32, - "require_processor": false, - "scalable_attention": true, - "stacked_params_mapping": [ - [ - ".qkv_proj", - ".q", - "q" - ], - [ - ".qkv_proj", - ".k", - "k" - ], - [ - ".qkv_proj", - ".v", - "v" - ] - ], - "task_specific_params": null, - "text_len": 512, - "tie_word_embeddings": false, - "tokenizer_kwargs": { - "add_special_tokens": true, - "max_length": 512, - "return_attention_mask": true, - "return_tensors": "pt", - "truncation": true - }, - "use_cache": true, - "use_return_dict": true, - "vocab_size": 32128 - }, - "chat_template_enable_thinking": false, - "is_chat_model": false, - "lora_config": null, - "prefix": "t5", - "quant_config": null, - "treat_empty_as_dot": false - } - ], - "text_encoder_precisions": [ - "fp32" - ], - "ti2v_task": false, - "upsampler_config": { - "_resolved_attention_backend": null, - "arch_config": { - "stacked_params_mapping": [] - } - }, - "upsampler_precision": "fp32", - "vae_config": { - "_resolved_attention_backend": null, - "arch_config": { - "attn_scales": [], - "base_dim": 96, - "clip_output": true, - "decoder_base_dim": null, - "dim_mult": [ - 1, - 2, - 4, - 4 - ], - "dropout": 0.0, - "in_channels": 3, - "is_residual": false, - "latents_mean": [ - -0.7571, - -0.7089, - -0.9113, - 0.1075, - -0.1745, - 0.9653, - -0.1517, - 1.5508, - 0.4134, - -0.0715, - 0.5517, - -0.3632, - -0.1922, - -0.9497, - 0.2503, - -0.2921 - ], - "latents_std": [ - 2.8184, - 1.4541, - 2.3275, - 2.6558, - 1.2196, - 1.7708, - 2.6052, - 2.0743, - 3.2687, - 2.1526, - 2.8652, - 1.5579, - 1.6382, - 1.1253, - 2.8251, - 1.916 - ], - "num_res_blocks": 2, - "out_channels": 3, - "patch_size": null, - "scale_factor_spatial": 8, - "scale_factor_temporal": 4, - "scaling_factor": "", - "spatial_compression_ratio": 8, - "stacked_params_mapping": [], - "temperal_downsample": [ - false, - true, - true - ], - "temporal_compression_ratio": 4, - "z_dim": 16 - }, - "blend_num_frames": 8, - "load_decoder": true, - "load_encoder": false, - "tile_sample_min_height": 128, - "tile_sample_min_num_frames": 16, - "tile_sample_min_width": 256, - "tile_sample_stride_height": 192, - "tile_sample_stride_num_frames": 12, - "tile_sample_stride_width": 192, - "use_feature_cache": true, - "use_light_vae": false, - "use_parallel_tiling": false, - "use_temporal_scaling_frames": true, - "use_temporal_tiling": false, - "use_tiling": true - }, - "vae_decode_precision": "bf16", - "vae_precision": "fp32", - "vae_sp": false, - "vae_tiling": false, - "warp_denoising_step": true - }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" -} diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/attention_precision_and_flow_shift.json b/fastvideo/tests/api/config_snapshot_goldens/config/attention_precision_and_flow_shift.json index 702b2e4f8..0034f1ea4 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/attention_precision_and_flow_shift.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/attention_precision_and_flow_shift.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.5, - "VSA_tile_size": 256, - "attention_backend": "TORCH_SDPA", - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -424,5 +326,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": "TORCH_SDPA", + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.5, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "fp32", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/boundary_ratio.json b/fastvideo/tests/api/config_snapshot_goldens/config/boundary_ratio.json index bec7bc703..0c1271ba0 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/boundary_ratio.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/boundary_ratio.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.2-T2V-A14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.8, "disable_autocast": false, @@ -394,7 +296,6 @@ ], "engine.precision.vae": "fp32", "engine.precision.vae_decode": "bf16", - "pipeline.boundary_ratio": 0.875, "pipeline.dmd_denoising_steps": [ 1000, 750, @@ -406,12 +307,6 @@ "pipeline.vae_sp": false } ], - [ - "route_flat_override_keys", - { - "pipeline.boundary_ratio": 0.8 - } - ], [ "derive_parallel_sizes", { @@ -445,5 +340,142 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.2-T2V-A14B-Diffusers", + "pipeline": { + "boundary_ratio": 0.8, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 12.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/cli/model_path_only.json b/fastvideo/tests/api/config_snapshot_goldens/config/experimental_keys.json similarity index 56% rename from fastvideo/tests/api/config_snapshot_goldens/cli/model_path_only.json rename to fastvideo/tests/api/config_snapshot_goldens/config/experimental_keys.json index 76324ff4e..397922720 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/cli/model_path_only.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/experimental_keys.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": false, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": null, - "init_weights_from_safetensors_2": null, - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -160,7 +62,7 @@ "dmd_denoising_steps": null, "embedded_cfg_scale": 6.0, "flow_shift": 3.0, - "flow_shift_sr": null, + "flow_shift_sr": 2.0, "image_encoder_config": { "_resolved_attention_backend": null, "arch_config": { @@ -371,5 +273,200 @@ "vae_tiling": false, "warp_denoising_step": true }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" + "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": { + "flow_shift_sr": 2.0, + "ray_runtime_env": { + "pip": [ + "probe" + ] + } + }, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_disabled.json b/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_disabled.json index ac4c6349f..a7e147fd4 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_disabled.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_disabled.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": "", - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -406,5 +308,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": "", + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_path.json b/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_path.json index cd2ff3203..69c59c336 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_path.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_refine_lora_path.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": "/checkpoints/refine_lora.safetensors", - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -406,5 +308,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": "/checkpoints/refine_lora.safetensors", + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_vae_tile_sizes.json b/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_vae_tile_sizes.json index 1c7876d65..2fa548055 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_vae_tile_sizes.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/ltx2_vae_tile_sizes.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": 512, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": 64, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -406,5 +308,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": 512, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": 64 + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/keys_without_typed_fields.json b/fastvideo/tests/api/config_snapshot_goldens/config/master_port_refine_enabled_boundary_ratio.json similarity index 71% rename from fastvideo/tests/api/config_snapshot_goldens/config/keys_without_typed_fields.json rename to fastvideo/tests/api/config_snapshot_goldens/config/master_port_refine_enabled_boundary_ratio.json index 363f748f8..0507580ac 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/keys_without_typed_fields.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/master_port_refine_enabled_boundary_ratio.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": 29600, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.5, "disable_autocast": false, @@ -394,14 +296,6 @@ "pipeline.vae_sp": false } ], - [ - "route_flat_override_keys", - { - "engine.parallelism.master_port": 29600, - "pipeline.boundary_ratio": 0.5, - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -435,5 +329,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": 29600, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": 0.5, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/pipeline_config_json_path.json b/fastvideo/tests/api/config_snapshot_goldens/config/pipeline_config_json_path.json index 797f1abfa..109b8f0d6 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/pipeline_config_json_path.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/pipeline_config_json_path.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastHunyuan-diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -455,5 +357,138 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp16", + "fp16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastHunyuan-diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": "/fastvideo/configs/fasthunyuan_t2v.json", + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6, + "experimental": {}, + "flow_shift": 17, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/config/vae_tiling_typed.json b/fastvideo/tests/api/config_snapshot_goldens/config/vae_tiling_typed.json index fb8c824b6..504f1514f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/config/vae_tiling_typed.json +++ b/fastvideo/tests/api/config_snapshot_goldens/config/vae_tiling_typed.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -400,5 +302,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/environment/attention_backend.json b/fastvideo/tests/api/config_snapshot_goldens/environment/attention_backend.json index f9faadad0..023c6b062 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/environment/attention_backend.json +++ b/fastvideo/tests/api/config_snapshot_goldens/environment/attention_backend.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": "TORCH_SDPA", - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -371,5 +273,199 @@ "vae_tiling": false, "warp_denoising_step": true }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" + "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_attention_backend_from_env", + { + "engine.attention.backend": "TORCH_SDPA" + } + ], + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": "TORCH_SDPA", + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/environment/explicit_argument_wins_over_attention_backend.json b/fastvideo/tests/api/config_snapshot_goldens/environment/explicit_argument_wins_over_attention_backend.json index 8389d8362..0961e7c10 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/environment/explicit_argument_wins_over_attention_backend.json +++ b/fastvideo/tests/api/config_snapshot_goldens/environment/explicit_argument_wins_over_attention_backend.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": "FLASH_ATTN", - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -371,5 +273,193 @@ "vae_tiling": false, "warp_denoising_step": true }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" + "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": "FLASH_ATTN", + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/environment/inference_torch_compile.json b/fastvideo/tests/api/config_snapshot_goldens/environment/inference_torch_compile.json index 1ea79a99b..ec9a588a6 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/environment/inference_torch_compile.json +++ b/fastvideo/tests/api/config_snapshot_goldens/environment/inference_torch_compile.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": true, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -371,5 +273,198 @@ "vae_tiling": false, "warp_denoising_step": true }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" + "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_regional_compile_from_env", + { + "engine.compile.regional": true + } + ], + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": true, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/environment/vae_parallel.json b/fastvideo/tests/api/config_snapshot_goldens/environment/vae_parallel.json index a171005e2..5c93b8327 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/environment/vae_parallel.json +++ b/fastvideo/tests/api/config_snapshot_goldens/environment/vae_parallel.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": true, - "vae_parallel_decode_strategy": "all_gather", - "vae_parallel_encode": true, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -371,5 +273,193 @@ "vae_tiling": false, "warp_denoising_step": true }, - "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig" + "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode": true, + "pipeline.minimax_h3.vae_parallel_decode_strategy": "all_gather", + "pipeline.minimax_h3.vae_parallel_encode": true + } + ], + [ + "fill_pipeline_config_defaults[WanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": true, + "vae_parallel_decode_strategy": "all_gather", + "vae_parallel_encode": true, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/kwargs/disable_autocast.json b/fastvideo/tests/api/config_snapshot_goldens/kwargs/disable_autocast.json index f79c1d5c8..3024fd03e 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/kwargs/disable_autocast.json +++ b/fastvideo/tests/api/config_snapshot_goldens/kwargs/disable_autocast.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": true, @@ -427,5 +329,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": true, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/kwargs/torch_compile_kwargs_typed_and_extra.json b/fastvideo/tests/api/config_snapshot_goldens/kwargs/torch_compile_kwargs_typed_and_extra.json index e69bd2330..d6317c572 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/kwargs/torch_compile_kwargs_typed_and_extra.json +++ b/fastvideo/tests/api/config_snapshot_goldens/kwargs/torch_compile_kwargs_typed_and_extra.json @@ -1,109 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": { - "backend": "inductor", - "fullgraph": true, - "mode": "max-autotune", - "options": { - "triton.cudagraphs": false - } - }, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -434,5 +329,141 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": "inductor", + "dit_kwargs": {}, + "dynamic": null, + "enabled": true, + "extras": { + "options": { + "triton.cudagraphs": false + } + }, + "fullgraph": true, + "mode": "max-autotune", + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/kwargs/typed_offload_and_parallelism.json b/fastvideo/tests/api/config_snapshot_goldens/kwargs/typed_offload_and_parallelism.json index fd605e08a..0c4bc50fe 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/kwargs/typed_offload_and_parallelism.json +++ b/fastvideo/tests/api/config_snapshot_goldens/kwargs/typed_offload_and_parallelism.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 2, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 2, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 2, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -426,5 +328,137 @@ "pipeline.workload_type": "t2v" } ] - ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 2, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 2, + "master_port": null, + "sp_size": 2, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + } } diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Cam-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Cam-Diffusers.json index 1bb9d6a0d..9c45d73cf 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Cam-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Cam-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/DreamX-World-5B-Cam-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -439,6 +341,194 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.dreamx_world.DreamXWorld5BCamPipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[DreamXWorld5BCamPipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[DreamXWorld5BCamPipelineConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/DreamX-World-5B-Cam-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Diffusers.json index dc20743e8..c02918a05 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__DreamX-World-5B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/DreamX-World-5B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "color_correction_strength": 1.0, @@ -481,6 +383,205 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.dreamx_world.DreamXWorld5BARPipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[DreamXWorld5BARPipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[DreamXWorld5BARPipelineConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/DreamX-World-5B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastHunyuan-diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastHunyuan-diffusers.json index 8afdf6c00..b02828cac 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastHunyuan-diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastHunyuan-diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastHunyuan-diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -400,6 +302,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan.FastHunyuanConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[FastHunyuanConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp16", + "fp16" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6, + "pipeline.flow_shift": 17, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[FastHunyuanConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp16", + "fp16" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastHunyuan-diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6, + "experimental": {}, + "flow_shift": 17, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-FastH3-8-Step-V2.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-FastH3-8-Step-V2.json index ae4010358..a2febd6ea 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-FastH3-8-Step-V2.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-FastH3-8-Step-V2.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastVideo-FastH3-8-Step-V2", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_vae_config": { "_resolved_attention_backend": null, @@ -483,6 +385,191 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.minimax_h3.MiniMaxH3PipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MiniMaxH3PipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MiniMaxH3PipelineConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastVideo-FastH3-8-Step-V2", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-Minimax-FastH3-Preview-v0.2.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-Minimax-FastH3-Preview-v0.2.json index a78623179..43561d37a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-Minimax-FastH3-Preview-v0.2.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastVideo-Minimax-FastH3-Preview-v0.2.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastVideo-Minimax-FastH3-Preview-v0.2", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_vae_config": { "_resolved_attention_backend": null, @@ -483,6 +385,191 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.minimax_h3.MiniMaxH3PipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MiniMaxH3PipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MiniMaxH3PipelineConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastVideo-Minimax-FastH3-Preview-v0.2", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-1.3B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-1.3B-Diffusers.json index 058b0e553..c1903eaa9 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-1.3B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-1.3B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -376,6 +278,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.FastWan2_1_T2V_480P_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[FastWan2_1_T2V_480P_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 8.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[FastWan2_1_T2V_480P_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-14B-480P-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-14B-480P-Diffusers.json index d018c8732..ca5b98e9b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-14B-480P-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.1-T2V-14B-480P-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.1-T2V-14B-480P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -376,6 +278,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.FastWan2_1_T2V_480P_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[FastWan2_1_T2V_480P_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 8.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[FastWan2_1_T2V_480P_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.1-T2V-14B-480P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-Diffusers.json index 8b0b3cf94..3a0449d16 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.2-TI2V-5B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -377,6 +279,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.FastWan2_2_TI2V_5B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[FastWan2_2_TI2V_5B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[FastWan2_2_TI2V_5B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.2-TI2V-5B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-FullAttn-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-FullAttn-Diffusers.json index 439d44e9c..ea5a95ce4 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-FullAttn-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__FastWan2.2-TI2V-5B-FullAttn-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.2-TI2V-5B-FullAttn-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -377,6 +279,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.FastWan2_2_TI2V_5B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[FastWan2_2_TI2V_5B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[FastWan2_2_TI2V_5B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.2-TI2V-5B-FullAttn-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__GEN3C-Cosmos-7B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__GEN3C-Cosmos-7B-Diffusers.json index 6f3f70ca8..2091e2a58 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__GEN3C-Cosmos-7B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__GEN3C-Cosmos-7B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/GEN3C-Cosmos-7B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "autoregressive_chunk_frames": 121, "autoregressive_overlap_frames": 1, @@ -404,6 +306,193 @@ ] }, "pipeline_config_class": "fastvideo.configs.pipelines.gen3c.Gen3CConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Gen3CConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6, + "pipeline.flow_shift": 1.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Gen3CConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/GEN3C-Cosmos-7B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6, + "experimental": {}, + "flow_shift": 1.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HY-WorldPlay-Bidirectional-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HY-WorldPlay-Bidirectional-Diffusers.json index 86c7677ba..16f95f503 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HY-WorldPlay-Bidirectional-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HY-WorldPlay-Bidirectional-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/HY-WorldPlay-Bidirectional-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -457,6 +359,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hyworld.HYWorldConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[HYWorldConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp16", + "engine.precision.text_encoders": [ + "fp16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[HYWorldConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp16", + "text_encoders": [ + "fp16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/HY-WorldPlay-Bidirectional-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HunyuanGameCraft-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HunyuanGameCraft-Diffusers.json index 41da4829b..c0b142562 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HunyuanGameCraft-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__HunyuanGameCraft-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/HunyuanGameCraft-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -410,6 +312,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuangamecraft.HunyuanGameCraftPipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[HunyuanGameCraftPipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp16", + "fp16" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[HunyuanGameCraftPipelineConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp16", + "fp16" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/HunyuanGameCraft-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX-2.3-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX-2.3-Distilled-Diffusers.json index 4cc80a8de..e5c451cf2 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX-2.3-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX-2.3-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Diffusers.json index b570c125e..045ac0f16 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Distilled-Diffusers.json index 2a161a821..542e8b142 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-base.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-base.json index 1194f8ef0..467ea4046 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-base.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2-base.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-base", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-base", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Diffusers.json index 1379fb485..65aa2531d 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2.3-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2.3-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Distilled-Diffusers.json index 3426cf99a..7f137d333 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-base.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-base.json index 9bc07964a..646d47dbd 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-base.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LTX2.3-base.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2.3-base", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2.3-base", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-Dense-1.3B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-Dense-1.3B-Diffusers.json index 9bd069cb7..881abde1a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-Dense-1.3B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-Dense-1.3B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LingBot-Video-Dense-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -380,6 +282,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.lingbot_video.LingBotVideoT2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LingBotVideoT2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "fp32", + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LingBotVideoT2VConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": "fp32" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LingBot-Video-Dense-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-MoE-30B-A3B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-MoE-30B-A3B-Diffusers.json index 101527986..959eaa915 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-MoE-30B-A3B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-Video-MoE-30B-A3B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LingBot-Video-MoE-30B-A3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -380,6 +282,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.lingbot_video.LingBotVideoT2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LingBotVideoT2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "fp32", + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LingBotVideoT2VConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": "fp32" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LingBot-Video-MoE-30B-A3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-World-Base-Cam-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-World-Base-Cam-Diffusers.json index 8f6de4959..3c6cf14e5 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-World-Base-Cam-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LingBot-World-Base-Cam-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LingBot-World-Base-Cam-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.947, "disable_autocast": false, @@ -402,6 +304,195 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.lingbotworld.LingBotWorldI2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LingBotWorldI2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.boundary_ratio": 0.947, + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 10.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LingBotWorldI2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LingBot-World-Base-Cam-Diffusers", + "pipeline": { + "boundary_ratio": 0.947, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 10.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-I2V-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-I2V-Diffusers.json index 8041bcac3..edd469360 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-I2V-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-I2V-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-I2V-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -372,6 +274,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LongCatT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.longcat.enable_bsa": false, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LongCatT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-I2V-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-T2V-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-T2V-Diffusers.json index b206d52c5..fc705e946 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-T2V-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-T2V-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -372,6 +274,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LongCatT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.longcat.enable_bsa": false, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LongCatT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-VC-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-VC-Diffusers.json index 7e119fb5e..aaa0c9b8f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-VC-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__LongCat-Video-VC-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-VC-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -372,6 +274,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.longcat.LongCatT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LongCatT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.longcat.enable_bsa": false, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LongCatT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-VC-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__MMAudio-large-44k-v2-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__MMAudio-large-44k-v2-Diffusers.json index 323581e6e..1d05b442f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__MMAudio-large-44k-v2-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__MMAudio-large-44k-v2-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/MMAudio-large-44k-v2-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -401,6 +303,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.configs.pipelines.mmaudio.MMAudioV2AConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MMAudioV2AConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MMAudioV2AConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/MMAudio-large-44k-v2-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Diffusers.json index 9ba15bbe5..2ae3d53ac 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-2.0-Base-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-2.0-Base-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Distilled-Diffusers.json index 443449f39..c5dbffcd5 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-Base-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-2.0-Base-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-2.0-Base-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Diffusers.json index a9821f49d..8e465cae2 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-2.0-GTA-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-2.0-GTA-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Distilled-Diffusers.json index 00aad1009..8c01801e8 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-GTA-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-2.0-GTA-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-2.0-GTA-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Diffusers.json index 1ff2cb440..e08371157 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-2.0-TempleRun-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-2.0-TempleRun-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Distilled-Diffusers.json index 432b5a6f9..2470cdf5b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-2.0-TempleRun-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-2.0-TempleRun-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-2.0-TempleRun-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-3.0-Base-Distilled-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-3.0-Base-Distilled-Diffusers.json index 54b09b533..e84a971c9 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-3.0-Base-Distilled-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Matrix-Game-3.0-Base-Distilled-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Matrix-Game-3.0-Base-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -425,6 +327,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame3.MatrixGame3I2V720PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame3I2V720PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame3I2V720PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Matrix-Game-3.0-Base-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__SFWan2.2-I2V-A14B-Preview-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__SFWan2.2-I2V-A14B-Preview-Diffusers.json index c2adfcbb2..d51f0b9af 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__SFWan2.2-I2V-A14B-Preview-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__SFWan2.2-I2V-A14B-Preview-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/SFWan2.2-I2V-A14B-Preview-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.875, "disable_autocast": false, @@ -381,6 +283,214 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.SelfForcingWan2_2_T2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[SelfForcingWan2_2_T2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.boundary_ratio": 0.875, + "pipeline.dmd_denoising_steps": [ + 1000, + 850, + 700, + 550, + 350, + 275, + 200, + 125 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 12.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[SelfForcingWan2_2_T2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/SFWan2.2-I2V-A14B-Preview-Diffusers", + "pipeline": { + "boundary_ratio": 0.875, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 850, + 700, + 550, + 350, + 275, + 200, + 125 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 12.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Wan2.1-VSA-T2V-14B-720P-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Wan2.1-VSA-T2V-14B-720P-Diffusers.json index 339a6dd09..f58847010 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Wan2.1-VSA-T2V-14B-720P-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__Wan2.1-VSA-T2V-14B-720P-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Wan2.1-VSA-T2V-14B-720P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -372,6 +274,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V720PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V720PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V720PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Wan2.1-VSA-T2V-14B-720P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-1.0-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-1.0-Diffusers.json index 2d595ba46..0fa19ee71 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-1.0-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-1.0-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/stable-audio-open-1.0-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_channels": 2, "audio_end_in_s": 10.0, @@ -231,6 +133,188 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.stable_audio.StableAudioT2AConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[StableAudioT2AConfig]", + { + "engine.precision.dit": "fp16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[StableAudioT2AConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "fp16", + "image_encoder": "fp32", + "text_encoders": [], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/stable-audio-open-1.0-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-small-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-small-Diffusers.json index 0283cc50c..f6cb88cb1 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-small-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/FastVideo__stable-audio-open-small-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/stable-audio-open-small-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_channels": 2, "audio_end_in_s": 6.0, @@ -231,6 +133,188 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.stable_audio.StableAudioOpenSmallConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[StableAudioOpenSmallConfig]", + { + "engine.precision.dit": "fp16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[StableAudioOpenSmallConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "fp16", + "image_encoder": "fp32", + "text_encoders": [], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/stable-audio-open-small-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/IRMChen__Wan2.1-Fun-1.3B-Control-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/IRMChen__Wan2.1-Fun-1.3B-Control-Diffusers.json index eb9944fe6..066c69951 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/IRMChen__Wan2.1-Fun-1.3B-Control-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/IRMChen__Wan2.1-Fun-1.3B-Control-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "IRMChen/Wan2.1-Fun-1.3B-Control-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -406,6 +308,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WANV2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WANV2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "bf16", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WANV2VConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "bf16", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "IRMChen/Wan2.1-Fun-1.3B-Control-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/KyleShao__Cosmos-Predict2.5-2B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/KyleShao__Cosmos-Predict2.5-2B-Diffusers.json index 9ad956948..10f29036f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/KyleShao__Cosmos-Predict2.5-2B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/KyleShao__Cosmos-Predict2.5-2B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "KyleShao/Cosmos-Predict2.5-2B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -369,6 +271,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.cosmos2_5.Cosmos25Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Cosmos25Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 0.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Cosmos25Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "KyleShao/Cosmos-Predict2.5-2B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 0.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.3.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.3.json index 927c5ea73..1d44b0348 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.3.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.3.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Lightricks/LTX-2.3", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Lightricks/LTX-2.3", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.json index 2b43c541b..5a15b4c6d 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Lightricks__LTX-2.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Lightricks/LTX-2", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -353,6 +255,192 @@ "vocoder_precision": "bf16" }, "pipeline_config_class": "fastvideo.pipelines.basic.ltx2.pipeline_configs.LTX2T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LTX2T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LTX2T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Lightricks/LTX-2", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/MiniMaxAI__MiniMax-H3.json b/fastvideo/tests/api/config_snapshot_goldens/registry/MiniMaxAI__MiniMax-H3.json index 3f0c4f903..ba0d99d61 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/MiniMaxAI__MiniMax-H3.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/MiniMaxAI__MiniMax-H3.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "MiniMaxAI/MiniMax-H3", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_vae_config": { "_resolved_attention_backend": null, @@ -483,6 +385,191 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.minimax_h3.MiniMaxH3PipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MiniMaxH3PipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MiniMaxH3PipelineConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "MiniMaxAI/MiniMax-H3", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Tongyi-MAI__Z-Image-Turbo.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Tongyi-MAI__Z-Image-Turbo.json index d44154c33..6b064fa6b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Tongyi-MAI__Z-Image-Turbo.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Tongyi-MAI__Z-Image-Turbo.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Tongyi-MAI/Z-Image-Turbo", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -333,6 +235,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.zimage.ZImagePipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[ZImagePipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 0.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[ZImagePipelineConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Tongyi-MAI/Z-Image-Turbo", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 0.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-480P-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-480P-Diffusers.json index 6746fb19e..6a7bb64fa 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-480P-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-480P-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -406,6 +308,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanI2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanI2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanI2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-720P-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-720P-Diffusers.json index 25d793478..22cddd381 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-720P-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-I2V-14B-720P-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-I2V-14B-720P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -406,6 +308,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanI2V720PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanI2V720PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanI2V720PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-I2V-14B-720P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-1.3B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-1.3B-Diffusers.json index 2a4326c88..208dc635c 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-1.3B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-1.3B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -372,6 +274,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-14B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-14B-Diffusers.json index aebe6a559..01ebf35ce 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-14B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.1-T2V-14B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -372,6 +274,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanT2V720PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanT2V720PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanT2V720PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-14B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-I2V-A14B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-I2V-A14B-Diffusers.json index 9faeb6dfa..966fac4db 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-I2V-A14B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-I2V-A14B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.2-I2V-A14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.9, "disable_autocast": false, @@ -406,6 +308,195 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.Wan2_2_I2V_A14B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Wan2_2_I2V_A14B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.boundary_ratio": 0.9, + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Wan2_2_I2V_A14B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.2-I2V-A14B-Diffusers", + "pipeline": { + "boundary_ratio": 0.9, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-T2V-A14B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-T2V-A14B-Diffusers.json index 132a92394..64315414d 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-T2V-A14B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-T2V-A14B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.2-T2V-A14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.875, "disable_autocast": false, @@ -377,6 +279,206 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.Wan2_2_T2V_A14B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Wan2_2_T2V_A14B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.boundary_ratio": 0.875, + "pipeline.dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 12.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Wan2_2_T2V_A14B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.2-T2V-A14B-Diffusers", + "pipeline": { + "boundary_ratio": 0.875, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 12.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-TI2V-5B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-TI2V-5B-Diffusers.json index 18b824809..80321a01a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-TI2V-5B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/Wan-AI__Wan2.2-TI2V-5B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.2-TI2V-5B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -373,6 +275,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.Wan2_2_TI2V_5B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Wan2_2_TI2V_5B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Wan2_2_TI2V_5B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.2-TI2V-5B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.1-dev.json b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.1-dev.json index bfd4ca7a9..906166db6 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.1-dev.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.1-dev.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "black-forest-labs/FLUX.1-dev", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -393,6 +295,194 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.flux.FluxPipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[FluxPipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32", + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 3.5, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[FluxPipelineConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32", + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "black-forest-labs/FLUX.1-dev", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 3.5, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-dev.json b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-dev.json index 4a6357111..6c1b4d49f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-dev.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-dev.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "black-forest-labs/FLUX.2-dev", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -302,6 +204,192 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.flux_2.Flux2PipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Flux2PipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 4.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Flux2PipelineConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "black-forest-labs/FLUX.2-dev", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 4.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-4B.json b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-4B.json index 7f0f43969..a589de4d0 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-4B.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-4B.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "black-forest-labs/FLUX.2-klein-4B", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -340,6 +242,191 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.flux_2.Flux2KleinPipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Flux2KleinPipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Flux2KleinPipelineConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "black-forest-labs/FLUX.2-klein-4B", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-9B.json b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-9B.json index c0d789848..c6480c185 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-9B.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/black-forest-labs__FLUX.2-klein-9B.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "black-forest-labs/FLUX.2-klein-9B", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -340,6 +242,191 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.flux_2.Flux2KleinPipelineConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Flux2KleinPipelineConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Flux2KleinPipelineConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "black-forest-labs/FLUX.2-klein-9B", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-1.1-Dev.json b/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-1.1-Dev.json index 985c98cd1..982a44096 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-1.1-Dev.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-1.1-Dev.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "decart-ai/Lucy-Edit-1.1-Dev", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -437,6 +339,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.LucyEditDevConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LucyEditDevConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LucyEditDevConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "decart-ai/Lucy-Edit-1.1-Dev", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-Dev.json b/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-Dev.json index 3f4621d47..5512b8d66 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-Dev.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/decart-ai__Lucy-Edit-Dev.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "decart-ai/Lucy-Edit-Dev", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -437,6 +339,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.LucyEditDevConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LucyEditDevConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LucyEditDevConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "decart-ai/Lucy-Edit-Dev", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_i2v_step_distilled.json b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_i2v_step_distilled.json index 36cbc4486..403a8016d 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_i2v_step_distilled.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_i2v_step_distilled.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-480p_i2v_step_distilled", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -409,6 +311,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan15.Hunyuan15I2V480PStepDistilledConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Hunyuan15I2V480PStepDistilledConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 7, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Hunyuan15I2V480PStepDistilledConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-480p_i2v_step_distilled", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 7, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_t2v.json b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_t2v.json index 2184c5cab..b9335f0b4 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_t2v.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-480p_t2v.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-480p_t2v", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -409,6 +311,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan15.Hunyuan15T2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Hunyuan15T2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Hunyuan15T2V480PConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-480p_t2v", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_i2v_distilled.json b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_i2v_distilled.json index 620e5bc0d..8f4e5e998 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_i2v_distilled.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_i2v_distilled.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-720p_i2v_distilled", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -409,6 +311,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan15.Hunyuan15I2V720PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Hunyuan15I2V720PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 7, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Hunyuan15I2V720PConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-720p_i2v_distilled", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 7, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_t2v.json b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_t2v.json index 58dadbe7f..8cdc905d1 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_t2v.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo-1.5-Diffusers-720p_t2v.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-720p_t2v", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -409,6 +311,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan15.Hunyuan15T2V720PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Hunyuan15T2V720PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 9, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Hunyuan15T2V720PConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "hunyuanvideo-community/HunyuanVideo-1.5-Diffusers-720p_t2v", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 9, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo.json b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo.json index 6271641cd..6252832a5 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/hunyuanvideo-community__HunyuanVideo.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "hunyuanvideo-community/HunyuanVideo", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -400,6 +302,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan.HunyuanConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[HunyuanConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp16", + "fp16" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6, + "pipeline.flow_shift": 7, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[HunyuanConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp16", + "fp16" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "hunyuanvideo-community/HunyuanVideo", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6, + "experimental": {}, + "flow_shift": 7, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Lite-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Lite-5s-Diffusers.json index 5fb90ba5d..24e59d4e5 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Lite-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Lite-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-I2V-Lite-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5I2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5I2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5I2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-I2V-Lite-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-distilled-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-distilled-5s-Diffusers.json index 33aa6d772..7a745ceee 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-distilled-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-distilled-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-I2V-Pro-distilled-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5I2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5I2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5I2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-I2V-Pro-distilled-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-sft-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-sft-5s-Diffusers.json index b20ef7d6d..7d5abb656 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-sft-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-I2V-Pro-sft-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-I2V-Pro-sft-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5I2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5I2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5I2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-I2V-Pro-sft-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-distilled16steps-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-distilled16steps-5s-Diffusers.json index af81411a1..63b65a3dd 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-distilled16steps-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-distilled16steps-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-T2V-Lite-distilled16steps-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-T2V-Lite-distilled16steps-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-sft-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-sft-5s-Diffusers.json index a2e5decec..526910329 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-sft-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Lite-sft-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-T2V-Lite-sft-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-T2V-Lite-sft-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-distilled-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-distilled-5s-Diffusers.json index 0212e0d03..fa39de173 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-distilled-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-distilled-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-T2V-Pro-distilled-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-T2V-Pro-distilled-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers.json index 73c0fb019..a002e881b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/kandinskylab__Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "kandinskylab/Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -405,6 +307,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.kandinsky5.Kandinsky5T2VConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Kandinsky5T2VConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Kandinsky5T2VConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "kandinskylab/Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-1.3B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-1.3B-Diffusers.json index 509e4da59..70680d01a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-1.3B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-1.3B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "loayrashid/TurboWan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -372,6 +274,193 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.turbodiffusion.TurboDiffusionT2V_1_3B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[TurboDiffusionT2V_1_3B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[TurboDiffusionT2V_1_3B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "loayrashid/TurboWan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-14B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-14B-Diffusers.json index 0b05d9560..29dce7714 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-14B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.1-T2V-14B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "loayrashid/TurboWan2.1-T2V-14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -372,6 +274,193 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.turbodiffusion.TurboDiffusionT2V_14B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[TurboDiffusionT2V_14B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[TurboDiffusionT2V_14B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "loayrashid/TurboWan2.1-T2V-14B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.2-I2V-A14B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.2-I2V-A14B-Diffusers.json index 8d1bbd6b1..961666ad5 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.2-I2V-A14B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/loayrashid__TurboWan2.2-I2V-A14B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "loayrashid/TurboWan2.2-I2V-A14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.9, "disable_autocast": false, @@ -406,6 +308,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.turbodiffusion.TurboDiffusionI2V_A14B_Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[TurboDiffusionI2V_A14B_Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "pipeline.boundary_ratio": 0.9, + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[TurboDiffusionI2V_A14B_Config]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "loayrashid/TurboWan2.2-I2V-A14B-Diffusers", + "pipeline": { + "boundary_ratio": 0.9, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_bidirectional_zelda.json b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_bidirectional_zelda.json index 2bf106aa7..88b4c8302 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_bidirectional_zelda.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_bidirectional_zelda.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "mignonjia/mg_bidirectional_zelda", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "mignonjia/mg_bidirectional_zelda", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_causal_zelda.json b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_causal_zelda.json index 72e01364a..e5bf63cf3 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_causal_zelda.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_causal_zelda.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "mignonjia/mg_causal_zelda", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "mignonjia/mg_causal_zelda", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_longtuning_distilled_zelda.json b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_longtuning_distilled_zelda.json index 9d82ffd88..7bf39331c 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_longtuning_distilled_zelda.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_longtuning_distilled_zelda.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "mignonjia/mg_longtuning_distilled_zelda", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "mignonjia/mg_longtuning_distilled_zelda", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda.json b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda.json index b05ecd48f..312d82193 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "mignonjia/mg_sf_distilled_zelda", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "mignonjia/mg_sf_distilled_zelda", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda_1k_steps.json b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda_1k_steps.json index 5b12cd465..637e6e81a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda_1k_steps.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/mignonjia__mg_sf_distilled_zelda_1k_steps.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "mignonjia/mg_sf_distilled_zelda_1k_steps", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "context_noise": 0, @@ -461,6 +363,203 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.matrixgame2.MatrixGame2I2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[MatrixGame2I2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[MatrixGame2I2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "mignonjia/mg_sf_distilled_zelda_1k_steps", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 666, + 333 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2-2B-Video2World.json b/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2-2B-Video2World.json index 0a29bd10c..3ac3dc945 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2-2B-Video2World.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2-2B-Video2World.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "nvidia/Cosmos-Predict2-2B-Video2World", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "conditioning_strategy": "frame_replace", @@ -376,6 +278,193 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.cosmos.CosmosConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[CosmosConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6, + "pipeline.flow_shift": 1.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[CosmosConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "nvidia/Cosmos-Predict2-2B-Video2World", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6, + "experimental": {}, + "flow_shift": 1.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2.5-14B.json b/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2.5-14B.json index de554196a..9d23f6898 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2.5-14B.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/nvidia__Cosmos-Predict2.5-14B.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "nvidia/Cosmos-Predict2.5-14B", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -369,6 +271,193 @@ "vae_tiling": false }, "pipeline_config_class": "fastvideo.configs.pipelines.cosmos2_5.Cosmos25_14BConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Cosmos25_14BConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "bf16", + "pipeline.embedded_cfg_scale": 0.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Cosmos25_14BConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "nvidia/Cosmos-Predict2.5-14B", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 0.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/rand0nmr__SFWan2.2-T2V-A14B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/rand0nmr__SFWan2.2-T2V-A14B-Diffusers.json index 099793d9c..94e567d11 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/rand0nmr__SFWan2.2-T2V-A14B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/rand0nmr__SFWan2.2-T2V-A14B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "rand0nmr/SFWan2.2-T2V-A14B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.875, "disable_autocast": false, @@ -381,6 +283,214 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.SelfForcingWan2_2_T2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[SelfForcingWan2_2_T2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.boundary_ratio": 0.875, + "pipeline.dmd_denoising_steps": [ + 1000, + 850, + 700, + 550, + 350, + 275, + 200, + 125 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 12.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[SelfForcingWan2_2_T2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "rand0nmr/SFWan2.2-T2V-A14B-Diffusers", + "pipeline": { + "boundary_ratio": 0.875, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 850, + 700, + 550, + 350, + 275, + 200, + 125 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 12.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/robbyant__lingbot-world-v2-14b-causal-fast.json b/fastvideo/tests/api/config_snapshot_goldens/registry/robbyant__lingbot-world-v2-14b-causal-fast.json index 7e128dd97..809676afe 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/robbyant__lingbot-world-v2-14b-causal-fast.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/robbyant__lingbot-world-v2-14b-causal-fast.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "robbyant/lingbot-world-v2-14b-causal-fast", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.947, "disable_autocast": false, @@ -381,6 +283,195 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.configs.pipelines.lingbotworld2.LingBotWorld2CausalFastI2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[LingBotWorld2CausalFastI2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "fp32", + "pipeline.boundary_ratio": 0.947, + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 10.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[LingBotWorld2CausalFastI2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": "fp32" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "robbyant/lingbot-world-v2-14b-causal-fast", + "pipeline": { + "boundary_ratio": 0.947, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 10.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/stabilityai__stable-diffusion-3.5-medium.json b/fastvideo/tests/api/config_snapshot_goldens/registry/stabilityai__stable-diffusion-3.5-medium.json index 7d31de7f6..e0e410858 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/stabilityai__stable-diffusion-3.5-medium.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/stabilityai__stable-diffusion-3.5-medium.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "stabilityai/stable-diffusion-3.5-medium", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -475,6 +377,196 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.sd35.SD35Config", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[SD35Config]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32", + "fp32", + "bf16" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 0.0, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[SD35Config]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32", + "fp32", + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "stabilityai/stable-diffusion-3.5-medium", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 0.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p-2SR.json b/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p-2SR.json index ac7e546d9..8e405d214 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p-2SR.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p-2SR.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "weizhou03/HunyuanVideo-1.5-Diffusers-1080p-2SR", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -430,6 +332,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan15.Hunyuan15SR1080PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Hunyuan15SR1080PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 7, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Hunyuan15SR1080PConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "weizhou03/HunyuanVideo-1.5-Diffusers-1080p-2SR", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 7, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p.json b/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p.json index 10699a1bf..b2d7b807e 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__HunyuanVideo-1.5-Diffusers-1080p.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "weizhou03/HunyuanVideo-1.5-Diffusers-1080p", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -430,6 +332,195 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.hunyuan15.Hunyuan15SR1080PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[Hunyuan15SR1080PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "bf16", + "fp32" + ], + "engine.precision.vae": "fp16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 7, + "pipeline.vae_sp": true + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[Hunyuan15SR1080PConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16", + "fp32" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "weizhou03/HunyuanVideo-1.5-Diffusers-1080p", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 7, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__Wan2.1-Fun-1.3B-InP-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__Wan2.1-Fun-1.3B-InP-Diffusers.json index d65c36f35..5edc39991 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__Wan2.1-Fun-1.3B-InP-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/weizhou03__Wan2.1-Fun-1.3B-InP-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "weizhou03/Wan2.1-Fun-1.3B-InP-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -406,6 +308,194 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.WanI2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[WanI2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 3.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[WanI2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "weizhou03/Wan2.1-Fun-1.3B-InP-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/wlsaidhi__SFWan2.1-T2V-1.3B-Diffusers.json b/fastvideo/tests/api/config_snapshot_goldens/registry/wlsaidhi__SFWan2.1-T2V-1.3B-Diffusers.json index ae400a849..adbc5c742 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/wlsaidhi__SFWan2.1-T2V-1.3B-Diffusers.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/wlsaidhi__SFWan2.1-T2V-1.3B-Diffusers.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "wlsaidhi/SFWan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -377,6 +279,205 @@ "warp_denoising_step": true }, "pipeline_config_class": "fastvideo.models.wan.pipeline_config.SelfForcingWanT2V480PConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[SelfForcingWanT2V480PConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "engine.precision.vae_decode": "bf16", + "pipeline.dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "pipeline.embedded_cfg_scale": 6.0, + "pipeline.flow_shift": 5.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[SelfForcingWanT2V480PConfig]", + { + "pipeline.vae_tiling": false + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "wlsaidhi/SFWan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/registry/zai-org__GLM-Image.json b/fastvideo/tests/api/config_snapshot_goldens/registry/zai-org__GLM-Image.json index c4701ced6..33806d453 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/registry/zai-org__GLM-Image.json +++ b/fastvideo/tests/api/config_snapshot_goldens/registry/zai-org__GLM-Image.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": null, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "zai-org/GLM-Image", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -362,6 +264,193 @@ "vae_tiling": true }, "pipeline_config_class": "fastvideo.configs.pipelines.glm_image.GlmImageConfig", + "resolution_decisions": [ + [ + "fill_vae_parallel_from_env", + { + "pipeline.minimax_h3.vae_parallel_decode_strategy": "gather" + } + ], + [ + "fill_pipeline_config_defaults[GlmImageConfig]", + { + "engine.precision.dit": "bf16", + "engine.precision.image_encoder": "fp32", + "engine.precision.text_encoders": [ + "fp32" + ], + "engine.precision.vae": "fp32", + "pipeline.embedded_cfg_scale": 7.5, + "pipeline.flow_shift": 1.0, + "pipeline.vae_sp": false + } + ], + [ + "derive_parallel_sizes", + { + "engine.parallelism.hsdp_shard_dim": 1, + "engine.parallelism.sp_size": 1, + "engine.parallelism.tp_size": 1 + } + ], + [ + "fill_vae_tiling_default[GlmImageConfig]", + { + "pipeline.vae_tiling": true + } + ], + [ + "fill_runtime_defaults", + { + "engine.attention.moba_config": {}, + "engine.attention.vsa_sparsity": 0.0, + "engine.attention.vsa_tile_size": 256, + "engine.compile.audio_vae_enabled": false, + "engine.compile.regional": false, + "engine.compile.text_encoder_enabled": false, + "engine.compile.vae_enabled": false, + "pipeline.ltx2.legacy_native_noise_order": false, + "pipeline.ltx2.use_distilled_sigmas": true, + "pipeline.minimax_h3.taeh3_chunk_size": 5, + "pipeline.minimax_h3.vae_parallel_decode": false, + "pipeline.minimax_h3.vae_parallel_encode": false, + "pipeline.minimax_h3.video_decode_backend": "h3-vae", + "pipeline.workload_type": "t2v" + } + ] + ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "zai-org/GLM-Image", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 7.5, + "experimental": {}, + "flow_shift": 1.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/apps__dreamverse__serve_configs__streaming_demo.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/apps__dreamverse__serve_configs__streaming_demo.yaml.json index fc2bc51e2..50d8ec181 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/apps__dreamverse__serve_configs__streaming_demo.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/apps__dreamverse__serve_configs__streaming_demo.yaml.json @@ -1,112 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": true, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": { - "backend": "inductor", - "dynamic": false, - "fullgraph": true, - "mode": "max-autotune-no-cudagraphs" - }, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": { - "__class__": "fastvideo.layers.quantization.nvfp4_config.NVFP4Config", - "layer_profile": "refine", - "packed_modules_mapping": {}, - "retain_original_weights": null - }, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -408,12 +300,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -440,6 +326,148 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": "inductor", + "dit_kwargs": {}, + "dynamic": false, + "enabled": true, + "extras": {}, + "fullgraph": true, + "mode": "max-autotune-no-cudagraphs", + "regional": false, + "text_encoder_enabled": true, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": false, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": false, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": { + "text_encoder_quant": null, + "transformer_quant": "NVFP4" + }, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": "FastVideo/LTX2-Distilled-Diffusers", + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1024x1536.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1024x1536.yaml.json index d6f6d1e4d..d234fc488 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1024x1536.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1024x1536.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1280x832.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1280x832.yaml.json index 6d42d15e9..14687404c 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1280x832.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_1280x832.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_512x768.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_512x768.yaml.json index 8fbf99c3a..26b44f2fd 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_512x768.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_512x768.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_768x1280.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_768x1280.yaml.json index e56455936..3e9a96c74 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_768x1280.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_5s2_768x1280.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1024x1536.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1024x1536.yaml.json index 130c5facd..e488c0900 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1024x1536.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1024x1536.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1280x832.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1280x832.yaml.json index b980db5d6..f95532959 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1280x832.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_1280x832.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_512x768.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_512x768.yaml.json index d54eb95c0..bbeee04bd 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_512x768.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_512x768.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_768x1280.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_768x1280.yaml.json index 030cfc179..c33d20319 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_768x1280.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__i2v_8s3_768x1280.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1024x1536.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1024x1536.yaml.json index 9b95db56e..c2fe17b64 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1024x1536.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1024x1536.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1280x832.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1280x832.yaml.json index d00ef081d..4dfbd800a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1280x832.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_1280x832.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_512x768.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_512x768.yaml.json index 3e0352a35..2436c2b2d 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_512x768.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_512x768.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_768x1280.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_768x1280.yaml.json index 1752848b7..0826a2c9c 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_768x1280.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_5s2_768x1280.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1024x1536.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1024x1536.yaml.json index 214f6d8fe..d73d1384d 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1024x1536.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1024x1536.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1280x832.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1280x832.yaml.json index de16cbfb6..8f66b0e9b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1280x832.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_1280x832.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_512x768.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_512x768.yaml.json index 3c3d118c6..b9f2fccd1 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_512x768.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_512x768.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_768x1280.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_768x1280.yaml.json index 6c9d64823..365c199ce 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_768x1280.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__inference__ltx2_3__t2v_8s3_768x1280.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -393,12 +295,6 @@ "pipeline.ltx2.refine.num_inference_steps": 3 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -432,6 +328,145 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX-2.3-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 3, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 3 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3.yaml.json index b75ef5829..13446a56b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.9, - "VSA_tile_size": 64, - "attention_backend": "VIDEO_SPARSE_ATTN_H3", - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 4, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastVideo-Minimax-FastH3-Preview-v0.2", - "model_paths": {}, - "num_gpus": 4, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 4, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": true, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_vae_config": { "_resolved_attention_backend": null, @@ -532,6 +434,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": "VIDEO_SPARSE_ATTN_H3", + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.9, + "vsa_tile_size": 64 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 4, + "offload": { + "dit": false, + "dit_layerwise": false, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 4, + "master_port": null, + "sp_size": 4, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastVideo-Minimax-FastH3-Preview-v0.2", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": true, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_8step.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_8step.yaml.json index 2845f9aab..ee9de467c 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_8step.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_8step.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.8, - "VSA_tile_size": 64, - "attention_backend": "VIDEO_SPARSE_ATTN_H3", - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 4, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastVideo-FastH3-8-Step-V2", - "model_paths": {}, - "num_gpus": 4, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 4, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": true, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_vae_config": { "_resolved_attention_backend": null, @@ -532,6 +434,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": "VIDEO_SPARSE_ATTN_H3", + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.8, + "vsa_tile_size": 64 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 4, + "offload": { + "dit": false, + "dit_layerwise": false, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 4, + "master_port": null, + "sp_size": 4, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastVideo-FastH3-8-Step-V2", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": true, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_lora.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_lora.yaml.json index bf4c2f513..31797eadb 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_lora.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fasth3_lora.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": "FLASH_ATTN", - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 4, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "fasth3-dense-datafree", - "lora_path": "/path/to/adapter_model.safetensors", - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "MiniMaxAI/MiniMax-H3", - "model_paths": {}, - "num_gpus": 4, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 4, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": true, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_vae_config": { "_resolved_attention_backend": null, @@ -534,6 +436,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": "FLASH_ATTN", + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 4, + "offload": { + "dit": false, + "dit_layerwise": false, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 4, + "master_port": null, + "sp_size": 4, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "MiniMaxAI/MiniMax-H3", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "fasth3-dense-datafree", + "lora_path": "/path/to/adapter_model.safetensors", + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": true, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fastwan21_1_3b.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fastwan21_1_3b.yaml.json index 47d20b34c..fbab8de3b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fastwan21_1_3b.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_fastwan21_1_3b.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.8, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -440,6 +342,142 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.8, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": true, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan21_i2v_14b.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan21_i2v_14b.yaml.json index 20475ab9d..ee854032f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan21_i2v_14b.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan21_i2v_14b.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 2, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", - "model_paths": {}, - "num_gpus": 2, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 2, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 2, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -468,6 +370,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 2, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 2, + "master_port": null, + "sp_size": 2, + "tp_size": 2 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_t2v_a14b.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_t2v_a14b.yaml.json index f251e5fa1..d69de2a97 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_t2v_a14b.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_t2v_a14b.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 2, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.2-T2V-A14B-Diffusers", - "model_paths": {}, - "num_gpus": 2, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 2, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": 0.875, "disable_autocast": false, @@ -452,6 +354,143 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 2, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 2, + "master_port": null, + "sp_size": 2, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.2-T2V-A14B-Diffusers", + "pipeline": { + "boundary_ratio": 0.875, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 750, + 500, + 250 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 12.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_ti2v_5b.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_ti2v_5b.yaml.json index 2e98dbe6d..8e3bd0e1c 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_ti2v_5b.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__openai_wan22_ti2v_5b.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.2-TI2V-5B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -440,6 +342,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.2-TI2V-5B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__streaming_demo.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__streaming_demo.yaml.json index fc2bc51e2..50d8ec181 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__streaming_demo.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/examples__serving__streaming_demo.yaml.json @@ -1,112 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": false, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": true, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": true, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 2, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LTX2-Distilled-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": true, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": { - "backend": "inductor", - "dynamic": false, - "fullgraph": true, - "mode": "max-autotune-no-cudagraphs" - }, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": { - "__class__": "fastvideo.layers.quantization.nvfp4_config.NVFP4Config", - "layer_profile": "refine", - "packed_modules_mapping": {}, - "retain_original_weights": null - }, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "audio_decoder_config": { "_resolved_attention_backend": null, @@ -408,12 +300,6 @@ "pipeline.ltx2.refine.num_inference_steps": 2 } ], - [ - "route_flat_override_keys", - { - "pipeline.ltx2.refine.enabled": true - } - ], [ "derive_parallel_sizes", { @@ -440,6 +326,148 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": "inductor", + "dit_kwargs": {}, + "dynamic": false, + "enabled": true, + "extras": {}, + "fullgraph": true, + "mode": "max-autotune-no-cudagraphs", + "regional": false, + "text_encoder_enabled": true, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": false, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": false, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": { + "text_encoder_quant": null, + "transformer_quant": "NVFP4" + }, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LTX2-Distilled-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": "FastVideo/LTX2-Distilled-Diffusers", + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": true, + "audio_noise_path": null, + "enabled": true, + "guidance_scale": 1.0, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": 2, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": { + "refine": { + "add_noise": true, + "enabled": true, + "guidance_scale": 1.0, + "num_inference_steps": 2 + } + }, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_fasthunyuan.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_fasthunyuan.yaml.json index 065bae95b..1db667365 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_fasthunyuan.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_fasthunyuan.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 4, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastHunyuan-Diffusers", - "model_paths": {}, - "num_gpus": 4, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 4, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -462,6 +364,139 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 4, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 4, + "master_port": null, + "sp_size": 4, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp16", + "fp16" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastHunyuan-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 17.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_flux2_klein.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_flux2_klein.yaml.json index 482d2f6df..1d4f9f46f 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_flux2_klein.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_flux2_klein.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "black-forest-labs/FLUX.2-klein-4B", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2i" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -403,6 +305,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "fp32", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "black-forest-labs/FLUX.2-klein-4B", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": null, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2i" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_hunyuan.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_hunyuan.yaml.json index 4a6bd4d2d..83fae4dd2 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_hunyuan.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_hunyuan.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 4, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": true, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "hunyuanvideo-community/HunyuanVideo", - "model_paths": {}, - "num_gpus": 4, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 4, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -462,6 +364,139 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 4, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 4, + "master_port": null, + "sp_size": 4, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp16", + "fp16" + ], + "vae": "fp16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "hunyuanvideo-community/HunyuanVideo", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 7.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": true, + "vae_tiling": true, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat.yaml.json index d73171c4b..5b7759b51 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": false, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -434,6 +336,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": false, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_distill.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_distill.yaml.json index 761516bb4..5e0e31a72 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_distill.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_distill.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "distilled", - "lora_path": "FastVideo/LongCat-Video-T2V-Distilled-LoRA", - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -434,6 +336,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "distilled", + "lora_path": "FastVideo/LongCat-Video-T2V-Distilled-LoRA", + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_i2v.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_i2v.yaml.json index c5055ea52..b92b7033a 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_i2v.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_i2v.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-I2V-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -433,6 +335,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-I2V-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_refine_fromvideo.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_refine_fromvideo.yaml.json index 6a237c1fc..c9829f3ff 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_refine_fromvideo.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_refine_fromvideo.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "refinement", - "lora_path": "FastVideo/LongCat-Video-T2V-Refinement-LoRA", - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -443,6 +345,146 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-T2V-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "refinement", + "lora_path": "FastVideo/LongCat-Video-T2V-Refinement-LoRA", + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": [ + 4, + 4, + 8 + ], + "bsa_chunk_q": [ + 4, + 4, + 8 + ], + "bsa_sparsity": 0.875, + "enable_bsa": true + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_vc.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_vc.yaml.json index cf43678b1..4c86455e4 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_vc.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_longcat_vc.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/LongCat-Video-VC-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "bsa_cdf_threshold": null, @@ -434,6 +336,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "bf16" + ], + "vae": "bf16", + "vae_decode": null + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/LongCat-Video-VC-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": null, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": false + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan.yaml.json index 043d2d1e6..4c29997fc 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -435,6 +337,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_1.3B_VMoba.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_1.3B_VMoba.yaml.json index 492d43e9c..0b1c1bbdf 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_1.3B_VMoba.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_1.3B_VMoba.yaml.json @@ -1,124 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": { - "first_full_layer": 0, - "first_full_step": 12, - "moba_select_mode": "threshold", - "moba_threshold": 0.25, - "moba_threshold_type": "query_head", - "spatial_chunk_size": [ - 3, - 4 - ], - "spatial_layer": 1, - "spatial_topk": 20, - "st_chunk_size": [ - 4, - 6, - 4 - ], - "st_layer": 1, - "st_topk": 15, - "temporal_chunk_size": 2, - "temporal_layer": 1, - "temporal_topk": 3 - }, - "moba_config_path": "fastvideo/configs/backend/vmoba/wan_1.3B_77_480_832.json", - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Wan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -484,6 +364,160 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": { + "first_full_layer": 0, + "first_full_step": 12, + "moba_select_mode": "threshold", + "moba_threshold": 0.25, + "moba_threshold_type": "query_head", + "spatial_chunk_size": [ + 3, + 4 + ], + "spatial_layer": 1, + "spatial_topk": 20, + "st_chunk_size": [ + 4, + 6, + 4 + ], + "st_layer": 1, + "st_topk": 15, + "temporal_chunk_size": 2, + "temporal_layer": 1, + "temporal_topk": 3 + }, + "moba_config_path": "fastvideo/configs/backend/vmoba/wan_1.3B_77_480_832.json", + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Wan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA.yaml.json index c057a8c83..dc2b1d906 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.9, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/Wan2.1-VSA-T2V-14B-720P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -434,6 +336,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.9, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/Wan2.1-VSA-T2V-14B-720P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_480P.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_480P.yaml.json index 34b48279a..8b3b30303 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_480P.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_480P.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.9, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.1-T2V-14B-480P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -440,6 +342,142 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.9, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": true, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.1-T2V-14B-480P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_720P.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_720P.yaml.json index d7ae1b4a8..4ca024395 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_720P.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_14B_720P.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.9, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.1-T2V-14B-480P-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -440,6 +342,142 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.9, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": true, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.1-T2V-14B-480P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_1_3B.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_1_3B.yaml.json index 091e076fe..6606d5dfa 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_1_3B.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_1_3B.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.8, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": false, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.1-T2V-1.3B-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": false, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": false, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -440,6 +342,142 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.8, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": true, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": false, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": false, + "text_encoder": true, + "vae": false + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.1-T2V-1.3B-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 8.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_5B_720P.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_5B_720P.yaml.json index a8e0eafdc..68a5e8e1b 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_5B_720P.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_VSA_DMD_5B_720P.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": true, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 1, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "FastVideo/FastWan2.2-TI2V-5B-FullAttn-Diffusers", - "model_paths": {}, - "num_gpus": 1, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 1, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 1, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "t2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -442,6 +344,142 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": true, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 1, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 1, + "master_port": null, + "sp_size": 1, + "tp_size": 1 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "FastVideo/FastWan2.2-TI2V-5B-FullAttn-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": [ + 1000, + 757, + 522 + ], + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 5.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "t2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_i2v.yaml.json b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_i2v.yaml.json index ce7ee3209..b835a35f4 100644 --- a/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_i2v.yaml.json +++ b/fastvideo/tests/api/config_snapshot_goldens/yaml/scripts__inference__inference_wan_i2v.yaml.json @@ -1,102 +1,4 @@ { - "fastvideo_args": { - "VSA_sparsity": 0.0, - "VSA_tile_size": 256, - "attention_backend": null, - "boundary_ratio": 0.875, - "disable_autocast": false, - "dist_timeout": null, - "distributed_executor_backend": "mp", - "dit_cpu_offload": true, - "dit_layerwise_offload": true, - "enable_stage_verification": true, - "enable_torch_compile": false, - "enable_torch_compile_audio_vae": false, - "enable_torch_compile_text_encoder": false, - "enable_torch_compile_vae": false, - "h3_sequential_load": null, - "hsdp_replicate_dim": 1, - "hsdp_shard_dim": 2, - "image_encoder_cpu_offload": true, - "inference_mode": true, - "inference_torch_compile": false, - "init_weights_from_safetensors": "", - "init_weights_from_safetensors_2": "", - "lazy_module_load": null, - "lora_nickname": "default", - "lora_path": null, - "lora_strength": 1.0, - "lora_target_modules": null, - "ltx2_audio_latent_path": null, - "ltx2_initial_latent_path": null, - "ltx2_legacy_native_noise_order": false, - "ltx2_refine_add_noise": true, - "ltx2_refine_audio_noise_path": null, - "ltx2_refine_enabled": false, - "ltx2_refine_guidance_scale": 1.0, - "ltx2_refine_lora_path": null, - "ltx2_refine_noise_path": null, - "ltx2_refine_num_inference_steps": 3, - "ltx2_refine_transformer_path": null, - "ltx2_refine_upsampler_path": null, - "ltx2_use_distilled_sigmas": true, - "ltx2_vae_spatial_tile_overlap_in_pixels": null, - "ltx2_vae_spatial_tile_size_in_pixels": null, - "ltx2_vae_temporal_tile_overlap_in_frames": null, - "ltx2_vae_temporal_tile_size_in_frames": null, - "ltx2_vae_tiling": false, - "master_port": null, - "moba_config": {}, - "moba_config_path": null, - "mode": "inference", - "model_loaded": { - "transformer": true, - "upsampler": true, - "vae": true - }, - "model_path": "Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", - "model_paths": {}, - "num_gpus": 2, - "output_type": "pil", - "override_pipeline_cls_name": null, - "override_text_encoder_quant": null, - "override_text_encoder_safetensors": null, - "override_transformer_cls_name": null, - "pin_cpu_memory": true, - "preprocess_config": null, - "prompt_txt": null, - "ray_placement_group": null, - "ray_runtime_env": null, - "refine_add_noise": null, - "refine_audio_noise_path": null, - "refine_enabled": null, - "refine_guidance_scale": null, - "refine_lora_path": null, - "refine_noise_path": null, - "refine_num_inference_steps": null, - "refine_transformer_path": null, - "refine_upsampler_path": null, - "revision": null, - "sp_size": 2, - "taeh3_checkpoint": null, - "taeh3_chunk_size": 5, - "text_encoder_cpu_offload": true, - "torch_compile_kwargs": {}, - "torch_compile_kwargs_audio_vae": {}, - "torch_compile_kwargs_dit": {}, - "torch_compile_kwargs_text_encoder": {}, - "torch_compile_kwargs_vae": {}, - "tp_size": 2, - "transformer_quant": null, - "trust_remote_code": false, - "use_fsdp_inference": false, - "vae_cpu_offload": true, - "vae_parallel_decode": false, - "vae_parallel_decode_strategy": "gather", - "vae_parallel_encode": false, - "video_decode_backend": "h3-vae", - "workload_type": "i2v" - }, "pipeline_config": { "boundary_ratio": null, "disable_autocast": false, @@ -468,6 +370,138 @@ } ] ], + "resolved_config": { + "engine": { + "attention": { + "backend": null, + "moba_config": {}, + "moba_config_path": null, + "vsa_sparsity": 0.0, + "vsa_tile_size": 256 + }, + "compile": { + "audio_vae_enabled": false, + "audio_vae_kwargs": {}, + "backend": null, + "dit_kwargs": {}, + "dynamic": null, + "enabled": false, + "extras": {}, + "fullgraph": null, + "mode": null, + "regional": false, + "text_encoder_enabled": false, + "text_encoder_kwargs": {}, + "vae_enabled": false, + "vae_kwargs": {} + }, + "disable_autocast": false, + "enable_stage_verification": true, + "execution_backend": "mp", + "num_gpus": 2, + "offload": { + "dit": true, + "dit_layerwise": true, + "image_encoder": true, + "lazy_module_load": null, + "pin_cpu_memory": true, + "text_encoder": true, + "vae": true + }, + "parallelism": { + "dist_timeout": null, + "hsdp_replicate_dim": 1, + "hsdp_shard_dim": 2, + "master_port": null, + "sp_size": 2, + "tp_size": 2 + }, + "precision": { + "dit": "bf16", + "image_encoder": "fp32", + "text_encoders": [ + "fp32" + ], + "vae": "fp32", + "vae_decode": "bf16" + }, + "quantization": null, + "use_fsdp_inference": false + }, + "mode": "inference", + "model_path": "Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", + "pipeline": { + "boundary_ratio": null, + "components": { + "config_root": null, + "lora_nickname": "default", + "lora_path": null, + "lora_strength": 1.0, + "lora_target_modules": null, + "override_pipeline_cls_name": null, + "override_transformer_cls_name": null, + "pipeline_config_path": null, + "text_encoder_weights": null, + "transformer_2_weights": null, + "transformer_weights": null, + "upsampler_weights": null, + "vae_weights": null + }, + "dit": {}, + "dmd_denoising_steps": null, + "embedded_cfg_scale": 6.0, + "experimental": {}, + "flow_shift": 3.0, + "longcat": { + "bsa_cdf_threshold": null, + "bsa_chunk_k": null, + "bsa_chunk_q": null, + "bsa_sparsity": null, + "enable_bsa": null + }, + "ltx2": { + "audio_latent_path": null, + "initial_latent_path": null, + "legacy_native_noise_order": false, + "refine": { + "add_noise": null, + "audio_noise_path": null, + "enabled": null, + "guidance_scale": null, + "image_crf": null, + "lora_path": null, + "noise_path": null, + "num_inference_steps": null, + "transformer_path": null, + "video_position_offset_sec": null + }, + "use_distilled_sigmas": true, + "vae_spatial_tile_overlap_in_pixels": null, + "vae_spatial_tile_size_in_pixels": null, + "vae_temporal_tile_overlap_in_frames": null, + "vae_temporal_tile_size_in_frames": null + }, + "minimax_h3": { + "sequential_load": null, + "taeh3_checkpoint": null, + "taeh3_chunk_size": 5, + "vae_parallel_decode": false, + "vae_parallel_decode_strategy": "gather", + "vae_parallel_encode": false, + "video_decode_backend": "h3-vae" + }, + "output_type": "pil", + "preset": null, + "preset_overrides": {}, + "preset_version": null, + "vae": {}, + "vae_sp": false, + "vae_tiling": false, + "workload_type": "i2v" + }, + "revision": null, + "trust_remote_code": false + }, "sampling_param": { "action_list": null, "action_path": null, diff --git a/fastvideo/tests/api/test_compat_translation.py b/fastvideo/tests/api/test_compat_translation.py index 45e8a51b4..5eafffb38 100644 --- a/fastvideo/tests/api/test_compat_translation.py +++ b/fastvideo/tests/api/test_compat_translation.py @@ -8,6 +8,8 @@ from __future__ import annotations import pytest from fastvideo.api.compat import ( + FROM_PRETRAINED_KWARGS, + _FROM_PRETRAINED_FIELDS, from_pretrained_kwargs_to_config, request_to_sampling_param, ) @@ -21,7 +23,7 @@ class TestFromPretrainedKwargsTranslation: """The ``from_pretrained`` keyword ``torch_compile_kwargs={...}`` gets split across the four first-class :class:`CompileConfig` fields and anything unknown falls into ``extras``. Keywords outside the - ``from_pretrained`` set are rejected with their typed path.""" + ``from_pretrained`` set are rejected.""" def test_empty_kwargs_produces_empty_extras(self) -> None: config = from_pretrained_kwargs_to_config( @@ -32,10 +34,18 @@ class TestFromPretrainedKwargsTranslation: assert compile_config.extras == {} assert compile_config.backend is None - def test_other_keyword_names_its_typed_path(self) -> None: - with pytest.raises(TypeError, match="ltx2_vae_tiling -> pipeline.vae_tiling"): + def test_other_keyword_points_to_from_config(self) -> None: + with pytest.raises(TypeError, match=r"does not accept ltx2_vae_tiling\. It accepts only these keywords: " + r"(.|\n)*VideoGenerator\.from_config"): from_pretrained_kwargs_to_config("/models/ltx2", {"ltx2_vae_tiling": True}) + def test_keyword_fields_are_the_from_pretrained_keywords(self) -> None: + """Every keyword with a schema field sets one field; ``torch_compile_kwargs`` and ``nvfp4_fa4`` have none.""" + assert set(_FROM_PRETRAINED_FIELDS) == FROM_PRETRAINED_KWARGS - {"torch_compile_kwargs", "nvfp4_fa4"} + assert len(set(_FROM_PRETRAINED_FIELDS.values())) == len(_FROM_PRETRAINED_FIELDS) + config = from_pretrained_kwargs_to_config("/models/wan", {"dit_cpu_offload": False, "sp_size": 2}) + assert config.engine.offload.dit is False and config.engine.parallelism.sp_size == 2 + class TestCompileConfigRoundTrip: """typed CompileConfig -> ``torch_compile_kwargs(resolved_config)`` diff --git a/fastvideo/tests/api/test_config_snapshot_matches_golden.py b/fastvideo/tests/api/test_config_snapshot_matches_golden.py index d072f85bf..268e8f0ff 100644 --- a/fastvideo/tests/api/test_config_snapshot_matches_golden.py +++ b/fastvideo/tests/api/test_config_snapshot_matches_golden.py @@ -1,14 +1,12 @@ # SPDX-License-Identifier: Apache-2.0 -"""Compare the final FastVideoArgs, PipelineConfig, and SamplingParam of every snapshot case with its golden file. +"""Compare the resolved config, PipelineConfig, resolution decisions, and SamplingParam of every snapshot case with +its golden file. -The cases and the serializer live in ``fastvideo/tests/api/config_snapshot.py``. Every entry of a snapshot must equal -the golden file, except ``resolution_decisions``: each decision that the golden file records must still be made with -the same value, by the same step, in the same step order, and resolution steps may decide further paths. After an -intended behavior change, regenerate the golden files with ``python -m fastvideo.tests.api.config_snapshot`` and -review the JSON diff. +The cases and the serializer live in ``fastvideo/tests/api/config_snapshot.py``. Every entry of a snapshot, including +the resolution decisions, must equal the golden file. After an intended behavior change, regenerate the golden files +with ``python -m fastvideo.tests.api.config_snapshot`` and review the JSON diff. """ import json -from typing import Any import pytest @@ -21,20 +19,6 @@ from fastvideo.tests.api.config_snapshot import ( ) SNAPSHOT_CASES = collect_cases() -DECISIONS = "resolution_decisions" - - -def _missing_decisions(golden: list[Any], current: list[Any]) -> list[str]: - """Golden decisions that the current snapshot no longer makes, and a changed order of the deciding steps.""" - decided = {(source, path): value for source, values in current for path, value in values.items()} - missing = [ - f" {source}: {path}={value!r} (current={decided.get((source, path), '')!r})" - for source, values in golden for path, value in values.items() if decided.get((source, path), ...) != value - ] - current_sources = iter(source for source, _ in current) - if not all(source in current_sources for source, _ in golden): - missing.append(f" step order changed: golden={[s for s, _ in golden]} current={[s for s, _ in current]}") - return missing @pytest.mark.parametrize("case", SNAPSHOT_CASES, ids=[case.case_id for case in SNAPSHOT_CASES]) @@ -46,15 +30,7 @@ def test_config_snapshot_matches_golden(case): assert case.golden_path.exists(), (f"{case.case_id} has no golden file at {case.golden_path}. " "Run `python -m fastvideo.tests.api.config_snapshot`.") golden = json.loads(case.golden_path.read_text()) - golden_values = {key: value for key, value in golden.items() if key != DECISIONS} - current_values = {key: value for key, value in current.items() if key != DECISIONS} - if current_values != golden_values: + if current != golden: pytest.fail(f"{case.case_id} differs from {case.golden_path.name}:\n" - f"{describe_diff(golden_values, current_values)}\n" + f"{describe_diff(golden, current)}\n" "If the change is intended, run `python -m fastvideo.tests.api.config_snapshot`.") - if (DECISIONS in golden) != (DECISIONS in current): - pytest.fail(f"{case.case_id}: {DECISIONS} is present in only one of the golden file and the snapshot") - missing = _missing_decisions(golden.get(DECISIONS, []), current.get(DECISIONS, [])) - if missing: - pytest.fail(f"{case.case_id} no longer makes these decisions of {case.golden_path.name}:\n" + - "\n".join(missing) + "\nIf the change is intended, run `python -m fastvideo.tests.api.config_snapshot`.") diff --git a/fastvideo/tests/api/test_fastvideo_args_freeze.py b/fastvideo/tests/api/test_fastvideo_args_freeze.py deleted file mode 100644 index a1e3bf65a..000000000 --- a/fastvideo/tests/api/test_fastvideo_args_freeze.py +++ /dev/null @@ -1,86 +0,0 @@ -# SPDX-License-Identifier: Apache-2.0 -"""A FastVideoArgs built from a resolved config is read-only, and every later change is a recorded override.""" -import pickle - -import pytest - -from fastvideo.api.compat import generator_config_to_fastvideo_args -from fastvideo.fastvideo_args import FastVideoArgs -from fastvideo.tests.api.config_snapshot import isolated_environment - -WAN_T2V = "Wan-AI/Wan2.1-T2V-1.3B-Diffusers" - - -def _resolved_args(raw=None, env_values=None): - with isolated_environment(env_values): - return generator_config_to_fastvideo_args({"model_path": WAN_T2V, **(raw or {})}) - - -def test_config_fields_are_read_only_after_resolution(): - args = _resolved_args() - - with pytest.raises(AttributeError, match="use fastvideo_args.override"): - args.dit_cpu_offload = False - with pytest.raises(AttributeError, match="pipeline_config.flow_shift"): - args.pipeline_config.flow_shift = 1.0 - - args.model_loaded["transformer"] = False - args.model_paths = {"transformer": "/tmp/transformer"} - args.pipeline_config.vae_config.load_encoder = True - - -def test_directly_built_args_stay_writable(): - with isolated_environment(): - args = FastVideoArgs(model_path=WAN_T2V) - - args.dit_cpu_offload = False - assert args.resolved_config is None - - -def test_override_is_logged_and_recorded_on_the_resolved_config(): - args = _resolved_args() - - args.override("test:source", {"dit_cpu_offload": False, "pipeline_config.flow_shift": 2.0}) - - assert args.dit_cpu_offload is False - assert args.pipeline_config.flow_shift == 2.0 - assert args.override_log == [("test:source", {"dit_cpu_offload": False, "pipeline_config.flow_shift": 2.0})] - assert args.resolved_config.provenance("engine.offload.dit").source == "test:source" - assert args.resolved_config.pipeline.flow_shift == 2.0 - - -def test_unified_memory_policy_is_a_recorded_override(monkeypatch): - from fastvideo.platforms import current_platform - - args = _resolved_args({"engine": {"offload": {"dit_layerwise": False}}}) - monkeypatch.setattr(current_platform, "has_unified_memory", lambda device_id: True) - monkeypatch.setattr(current_platform, "get_device_name", lambda device_id: "test device") - - args.finalize_device_offload_policy(0) - - assert args.dit_cpu_offload is False and args.vae_cpu_offload is False - assert args.lazy_module_load is True - sources = [source for source, _ in args.override_log] - assert sources == ["device_policy:unified_memory", "device_policy:lazy_module_load"] - assert args.resolved_config.provenance("engine.offload.vae").source == "device_policy:unified_memory" - - -def test_explicit_false_wins_over_the_environment(): - env = {"FASTVIDEO_INFERENCE_TORCH_COMPILE": True, "FASTVIDEO_VAE_PARALLEL_DECODE": True} - - explicit = _resolved_args({ - "engine": {"compile": {"regional": False}}, - "pipeline": {"minimax_h3": {"vae_parallel_decode": False}}, - }, env) - unset = _resolved_args(env_values=env) - - assert (explicit.inference_torch_compile, explicit.vae_parallel_decode) == (False, False) - assert (unset.inference_torch_compile, unset.vae_parallel_decode) == (True, True) - - -def test_pickled_args_stay_read_only(): - args = pickle.loads(pickle.dumps(_resolved_args())) - - assert args.resolved_config.engine.num_gpus == 1 - with pytest.raises(AttributeError): - args.num_gpus = 2 diff --git a/fastvideo/tests/api/test_generator_config_flat_names.py b/fastvideo/tests/api/test_generator_config_flat_names.py deleted file mode 100644 index 7275bd4ff..000000000 --- a/fastvideo/tests/api/test_generator_config_flat_names.py +++ /dev/null @@ -1,30 +0,0 @@ -# SPDX-License-Identifier: Apache-2.0 -"""Every ``GeneratorConfig`` field must have a defined place in the flat keyword API. - -``fastvideo.api.compat`` converts between ``GeneratorConfig`` and the flat keywords of -``VideoGenerator.from_pretrained`` / ``FastVideoArgs`` through each field's ``flat_name`` metadata. A field without a -flat name must be listed in ``_SPECIALLY_MAPPED_PATHS``, so a new field cannot be dropped silently by the conversion. -""" -from fastvideo.api.compat import _FLAT_NAME_FIELDS, _SPECIALLY_MAPPED_PATHS, _schema_fields -from fastvideo.api.schema import FLAT_NAME, GeneratorConfig - - -def test_every_field_has_a_flat_name_or_a_special_mapping() -> None: - unmapped = [ - dotted_path for dotted_path, config_field, _ in _schema_fields(GeneratorConfig) - if FLAT_NAME not in config_field.metadata and dotted_path not in _SPECIALLY_MAPPED_PATHS - ] - assert unmapped == [] - - -def test_flat_names_are_unique() -> None: - flat_names = [ - config_field.metadata[FLAT_NAME] for _, config_field, _ in _schema_fields(GeneratorConfig) - if FLAT_NAME in config_field.metadata - ] - assert len(flat_names) == len(set(flat_names)) == len(_FLAT_NAME_FIELDS) - - -def test_special_mappings_name_existing_fields() -> None: - field_paths = {dotted_path for dotted_path, _, _ in _schema_fields(GeneratorConfig)} - assert set(_SPECIALLY_MAPPED_PATHS) <= field_paths diff --git a/fastvideo/tests/api/test_inference_resolution_steps.py b/fastvideo/tests/api/test_inference_resolution_steps.py index 2cd0fea4f..a3e108a0e 100644 --- a/fastvideo/tests/api/test_inference_resolution_steps.py +++ b/fastvideo/tests/api/test_inference_resolution_steps.py @@ -110,11 +110,12 @@ def test_environment_takes_precedence_over_model_defaults(): "fill_vae_parallel_from_env", "fill_pipeline_config_defaults[WanT2V480PConfig]", "copy_refine_preset_overrides", - "route_flat_override_keys", "derive_parallel_sizes", "derive_vae_tiling_from_ltx2_tile_sizes", "fill_vae_tiling_default[WanT2V480PConfig]", "load_moba_config", + "validate_unsupported_fields", + "validate_experimental_keys", "validate_lora_strength", "validate_attention_backend", "validate_vae_parallel_decode_strategy", diff --git a/fastvideo/tests/api/test_resolved_runtime_config.py b/fastvideo/tests/api/test_resolved_runtime_config.py index 6d9f52a5d..bc5fe59a8 100644 --- a/fastvideo/tests/api/test_resolved_runtime_config.py +++ b/fastvideo/tests/api/test_resolved_runtime_config.py @@ -1,8 +1,7 @@ # SPDX-License-Identifier: Apache-2.0 -"""The resolved runtime config: materialization, flat names, runtime state, device policy, overrides, and roots.""" +"""The resolved runtime config: materialization, typed attributes, device policy, overrides, and roots.""" from __future__ import annotations -import dataclasses import json import pickle from contextlib import nullcontext @@ -12,15 +11,13 @@ import pytest import torch from fastvideo.api import device_policy -from fastvideo.api.compat import generator_config_to_fastvideo_args from fastvideo.api.errors import ConfigValidationError from fastvideo.api.inference_resolution import resolve_inference_config from fastvideo.api.parser import parse_config from fastvideo.api.schema import ExecutionMode, GeneratorConfig, WorkloadType from fastvideo.api.training_schema import (PreprocessRunConfig, TrainingRunConfig, load_resolved_run_config, resolve_preprocess_config, resolve_training_config) -from fastvideo.fastvideo_args import FastVideoArgs -from fastvideo.tests.api.config_snapshot import isolated_environment, to_jsonable +from fastvideo.tests.api.config_snapshot import isolated_environment WAN_T2V = "Wan-AI/Wan2.1-T2V-1.3B-Diffusers" LTX2 = "FastVideo/LTX2-Distilled-Diffusers" @@ -36,9 +33,9 @@ def test_resolution_builds_and_freezes_the_pipeline_config_once(monkeypatch): from fastvideo.configs.pipelines.base import PipelineConfig builds = [] - original = PipelineConfig.from_kwargs.__func__ - monkeypatch.setattr(PipelineConfig, "from_kwargs", - classmethod(lambda cls, kwargs: builds.append(dict(kwargs)) or original(cls, kwargs))) + original = PipelineConfig.from_source.__func__ + monkeypatch.setattr(PipelineConfig, "from_source", + classmethod(lambda cls, *args: builds.append(args) or original(cls, *args))) resolved = _resolve({"model_path": WAN_T2V, "pipeline": {"flow_shift": 5.0, "dit": {"prefix": "Probe"}}}) assert len(builds) == 1 @@ -49,60 +46,34 @@ def test_resolution_builds_and_freezes_the_pipeline_config_once(monkeypatch): resolved.pipeline_config.flow_shift = 1.0 -@pytest.mark.parametrize("raw", [ - { - "model_path": WAN_T2V, - "engine": { - "num_gpus": 2 - }, - "pipeline": { - "experimental": { - "master_port": 29600, - "prompt_txt": "prompts.txt", - "refine_enabled": True - } - }, - }, - { - "model_path": LTX2, - "pipeline": { - "preset_overrides": { - "refine": { - "enabled": True, - "num_inference_steps": 2, - "add_noise": False - } - }, - "ltx2": { - "vae_spatial_tile_size_in_pixels": 512 - }, - }, - }, -]) -def test_flat_names_return_the_values_that_fastvideo_args_held(raw): - resolved = _resolve(raw) - with isolated_environment(): - resolved_config = generator_config_to_fastvideo_args(resolved) +def test_only_typed_paths_and_reserved_names_are_attributes(): + resolved = _resolve({"model_path": WAN_T2V, "pipeline": {"workload_type": "t2v"}}) - # disable_autocast and boundary_ratio held their FastVideoArgs defaults; the typed field holds the input. - skipped = {"pipeline_config", "disable_autocast", "boundary_ratio"} - for config_field in dataclasses.fields(FastVideoArgs): - if config_field.name not in skipped: - expected = to_jsonable(getattr(resolved_config, config_field.name)) - assert to_jsonable(getattr(resolved, config_field.name)) == expected, config_field.name - assert to_jsonable(resolved.pipeline_config) == to_jsonable(resolved_config.pipeline_config) - assert resolved.workload_type is WorkloadType.T2V + assert resolved.pipeline.workload_type is WorkloadType.T2V assert resolved.mode is ExecutionMode.INFERENCE and resolved.inference_mode and not resolved.training_mode - - -def test_unknown_and_training_only_names_raise_attribute_error(): - resolved = _resolve({"model_path": WAN_T2V}) - assert getattr(resolved, "log_level_progress", "default") == "default" - assert not hasattr(resolved, "_loading_teacher_critic_model") - with pytest.raises(AttributeError, match="exists on TrainingRunConfig"): - resolved.learning_rate - assert resolved.preprocess_config is None + for name in ("num_gpus", "dit_cpu_offload", "workload_type", "learning_rate", "preprocess_config", "model_paths"): + with pytest.raises(AttributeError, match=f"GeneratorConfig has no field '{name}'"): + getattr(resolved, name) + with pytest.raises(AttributeError, match="read-only"): + resolved.model_paths = {} + + +def test_experimental_key_with_a_typed_path_is_rejected(): + with pytest.raises(ValueError, match=r"pipeline.experimental.flow_shift -> pipeline.flow_shift"): + _resolve({"model_path": WAN_T2V, "pipeline": {"experimental": {"flow_shift": 5.0}}}) + + +def test_fields_without_a_runtime_reader_are_rejected(): + with pytest.raises(NotImplementedError, match="pipeline.components.vae_weights"): + _resolve({"model_path": WAN_T2V, "pipeline": {"components": {"vae_weights": "/weights/vae.safetensors"}}}) + + +def test_experimental_model_only_attribute_reaches_the_pipeline_config(): + resolved = _resolve({"model_path": WAN_T2V, "pipeline": {"experimental": {"flow_shift_sr": 2.0}}}) + + assert resolved.pipeline_config.flow_shift_sr == 2.0 + assert resolved.pipeline.experimental["flow_shift_sr"] == 2.0 def test_overrides_and_pickling_carry_the_frozen_pipeline_config(): @@ -117,14 +88,15 @@ def test_overrides_and_pickling_carry_the_frozen_pipeline_config(): resolved.engine.num_gpus = 4 -def test_override_of_a_typed_home_updates_its_pipeline_config_mirror(): +def test_override_of_a_typed_home_leaves_the_pipeline_config_unchanged(): resolved = _resolve({"model_path": WAN_T2V}) + materialized_steps = resolved.pipeline_config.dmd_denoising_steps overridden = resolved.with_override("checkpoint:test", {"pipeline.dmd_denoising_steps": [999, 500]}) assert overridden.pipeline.dmd_denoising_steps == (999, 500) assert overridden.pipeline_config is resolved.pipeline_config - assert overridden.pipeline_config.dmd_denoising_steps == [999, 500] + assert overridden.pipeline_config.dmd_denoising_steps == materialized_steps assert overridden.provenance("pipeline.dmd_denoising_steps").source == "checkpoint:test" @@ -243,7 +215,7 @@ def test_pipeline_records_component_paths_and_shares_its_component_state(monkeyp assert stage.component_state is pipeline.component_state -def test_from_pretrained_keeps_the_dit_on_the_device_for_training(): +def test_training_resolution_keeps_the_dit_on_the_device(): from fastvideo.pipelines.composed_pipeline_base import ComposedPipelineBase built = {} @@ -278,10 +250,9 @@ def test_from_pretrained_keeps_the_dit_on_the_device_for_training(): _Pipeline.from_pretrained(WAN_T2V, resolved_config=resolved) - assert resolved.engine.offload.dit is True - assert built["resolved_config"].engine.offload.dit is False - assert built["resolved_config"].provenance("engine.offload.dit").source == ( - "ComposedPipelineBase.from_pretrained:training") + assert resolved.engine.offload.dit is False + assert resolved.provenance("engine.offload.dit").source == "keep_training_dit_on_device" + assert built["resolved_config"] is resolved def test_ltx2_checkpoint_refine_defaults_rebind_the_pipeline_config(tmp_path): @@ -350,7 +321,6 @@ def test_minimax_h3_checkpoint_schedule_rebinds_and_reaches_the_first_forward(tm assert seen == [pipeline.resolved_config] and pipeline.resolved_config is not resolved assert pipeline.resolved_config.pipeline.dmd_denoising_steps == tuple(steps) - assert pipeline.resolved_config.pipeline_config.dmd_denoising_steps == steps assert pipeline.resolved_config.provenance("pipeline.dmd_denoising_steps").source == ( "checkpoint:fastvideo_inference.json") diff --git a/fastvideo/tests/api/test_schema_parity_inventory.py b/fastvideo/tests/api/test_schema_parity_inventory.py index 47fec0b9b..0b23ee24b 100644 --- a/fastvideo/tests/api/test_schema_parity_inventory.py +++ b/fastvideo/tests/api/test_schema_parity_inventory.py @@ -10,7 +10,7 @@ from typing import Any, Union, get_args, get_origin, get_type_hints import yaml -from fastvideo.api import RunConfig, ServeConfig +from fastvideo.api import GeneratorConfig, RunConfig, ServeConfig from fastvideo.configs.pipelines.base import PipelineConfig from fastvideo.api.sampling_param import SamplingParam from fastvideo.entrypoints.cli.generate import GenerateSubcommand @@ -21,7 +21,6 @@ from fastvideo.entrypoints.openai.protocol import ( VideoGenerationsRequest, ) from fastvideo.entrypoints.openai.request_adapter import build_generation_request -from fastvideo.fastvideo_args import FastVideoArgs from fastvideo.utils import FlexibleArgumentParser _REPO_ROOT = Path(__file__).resolve().parents[3] @@ -46,6 +45,29 @@ def _flatten_status_section(section: dict, valid_statuses: set[str]) -> set[str] return names +def _get_dataclass_leaf_paths(cls: type, prefix: str = "") -> set[str]: + """Collect the dotted paths of the leaf fields of a nested config dataclass. + + A field whose annotation is a dataclass, or ``X | None`` of a dataclass, + is walked into; every other field, including a dict-valued field, is one + leaf. + """ + paths: set[str] = set() + hints = get_type_hints(cls) + for config_field in dataclasses.fields(cls): + annotation = hints[config_field.name] + if get_origin(annotation) in {types.UnionType, Union}: + non_none_args = [arg for arg in get_args(annotation) if arg is not type(None)] + if len(non_none_args) == 1: + annotation = non_none_args[0] + path = f"{prefix}{config_field.name}" + if dataclasses.is_dataclass(annotation): + paths.update(_get_dataclass_leaf_paths(annotation, f"{path}.")) + else: + paths.add(path) + return paths + + def _get_extra_dataclass_fields( package_names: str | tuple[str, ...], base_cls: type, @@ -163,11 +185,11 @@ def test_inventory_statuses_are_known() -> None: assert not unknown, f"Unknown statuses in surface inventory: {sorted(unknown)}" -def test_fastvideo_args_fields_are_classified() -> None: +def test_generator_config_fields_are_classified() -> None: inventory = _load_inventory() - expected = {f.name for f in dataclasses.fields(FastVideoArgs)} + expected = _get_dataclass_leaf_paths(GeneratorConfig) actual = _flatten_status_section( - inventory["surfaces"]["fastvideo_args"], + inventory["surfaces"]["generator_config"], set(inventory["status_definitions"]), ) assert actual == expected diff --git a/fastvideo/tests/api/test_typed_quant_flow.py b/fastvideo/tests/api/test_typed_quant_flow.py index 88bbe67dc..94973c81f 100644 --- a/fastvideo/tests/api/test_typed_quant_flow.py +++ b/fastvideo/tests/api/test_typed_quant_flow.py @@ -53,15 +53,14 @@ def test_no_typed_quant_leaves_the_dit_quant_config_unset() -> None: def test_apply_transformer_quant_pins_to_dit_config() -> None: - """Materialization must copy the ``transformer_quant`` instance onto - ``pipeline_config.dit_config.quant_config`` so the DiT loader sees + """Materialization must pin the config that ``transformer_quant`` names + on ``pipeline_config.dit_config.quant_config`` so the DiT loader sees it during construction. """ pipeline_config = SimpleNamespace(dit_config=SimpleNamespace(quant_config=None)) - nvfp4 = NVFP4Config() - _apply_transformer_quant(pipeline_config, nvfp4) - assert pipeline_config.dit_config.quant_config is nvfp4 + _apply_transformer_quant(pipeline_config, "NVFP4") + assert isinstance(pipeline_config.dit_config.quant_config, NVFP4Config) def test_apply_transformer_quant_does_not_overwrite_explicit_dit_config() -> None: @@ -70,5 +69,5 @@ def test_apply_transformer_quant_does_not_overwrite_explicit_dit_config() -> Non """ explicit = NVFP4Config(layer_profile="base") pipeline_config = SimpleNamespace(dit_config=SimpleNamespace(quant_config=explicit)) - _apply_transformer_quant(pipeline_config, NVFP4Config(layer_profile="refine")) + _apply_transformer_quant(pipeline_config, "NVFP4") assert pipeline_config.dit_config.quant_config is explicit diff --git a/fastvideo/tests/entrypoints/test_video_generator.py b/fastvideo/tests/entrypoints/test_video_generator.py index 25782b251..192a4bc50 100644 --- a/fastvideo/tests/entrypoints/test_video_generator.py +++ b/fastvideo/tests/entrypoints/test_video_generator.py @@ -661,11 +661,11 @@ def test_from_pretrained_convenience_kwargs_do_not_warn(monkeypatch): assert generator.config.engine.num_gpus == 4 -def test_from_pretrained_rejects_other_kwargs_with_their_config_path(monkeypatch): +def test_from_pretrained_rejects_other_kwargs_and_points_to_from_config(monkeypatch): captured = _patch_from_resolved_config(monkeypatch) _skip_model_definition(monkeypatch) - with pytest.raises(TypeError, match="workload_type -> pipeline.workload_type"): + with pytest.raises(TypeError, match=r"does not accept workload_type\.(.|\n)*VideoGenerator\.from_config"): VideoGenerator.from_pretrained( "test-model", num_gpus=4, diff --git a/fastvideo/tests/train/callbacks/test_validation.py b/fastvideo/tests/train/callbacks/test_validation.py index e34715e28..35fedf72e 100644 --- a/fastvideo/tests/train/callbacks/test_validation.py +++ b/fastvideo/tests/train/callbacks/test_validation.py @@ -1097,10 +1097,7 @@ class TestValidationResolvedConfigs: def _training_config(self) -> TrainingConfig: return TrainingConfig( distributed=DistributedConfig(num_gpus=2, sp_size=2, hsdp_shard_dim=2), - pipeline_config=PipelineConfig.from_kwargs({ - "model_path": self._MODEL_PATH, - "flow_shift": 3.0 - }), + pipeline_config=PipelineConfig.from_source(self._MODEL_PATH, {"flow_shift": 3.0}), model_path=self._MODEL_PATH, vsa_sparsity=0.5, ) @@ -1147,7 +1144,7 @@ class TestValidationResolvedConfigs: cb = _make_callback(sampling_timesteps=[1000, 757, 522]) training_config = self._training_config() cb.training_config = training_config - loaded_config = PipelineConfig.from_kwargs({"model_path": self._MODEL_PATH}) + loaded_config = PipelineConfig.from_source(self._MODEL_PATH) loaded_config.text_encoder_configs[0].arch_config.hidden_size = 1234 pipeline = SimpleNamespace(resolved_config=SimpleNamespace(pipeline_config=loaded_config)) diff --git a/fastvideo/tests/train/utils/test_moduleloader_attention_backend.py b/fastvideo/tests/train/utils/test_moduleloader_attention_backend.py index b52c79858..cc8280198 100644 --- a/fastvideo/tests/train/utils/test_moduleloader_attention_backend.py +++ b/fastvideo/tests/train/utils/test_moduleloader_attention_backend.py @@ -102,7 +102,7 @@ def _wan_training_config() -> TrainingConfig: """Training config with the Wan model definition and a two-GPU sequence-parallel layout.""" return TrainingConfig( distributed=DistributedConfig(num_gpus=2, sp_size=2, hsdp_shard_dim=2), - pipeline_config=PipelineConfig.from_kwargs({"model_path": _MODEL_PATH}), + pipeline_config=PipelineConfig.from_source(_MODEL_PATH), model_path=_MODEL_PATH, vsa_sparsity=0.5, ) diff --git a/fastvideo/train/utils/config.py b/fastvideo/train/utils/config.py index d396b0258..c700dfebe 100644 --- a/fastvideo/train/utils/config.py +++ b/fastvideo/train/utils/config.py @@ -265,22 +265,18 @@ def _parse_pipeline_config( pipeline_raw, dit_arch_overrides = _split_training_dit_arch_overrides(pipeline_raw) # Derive model_path from models.student.init_from — - # needed by PipelineConfig.from_kwargs. + # PipelineConfig.from_source picks the registry class from it. model_path: str | None = None student_cfg = models.get("student") if student_cfg is not None: init_from = student_cfg.get("init_from") if init_from is not None: model_path = str(init_from) + if model_path is None: + raise ValueError("models.student.init_from is required to build the pipeline config") - kwargs: dict[str, Any] = {"pipeline_config": pipeline_raw} - if model_path is not None: - kwargs["model_path"] = model_path - - if isinstance(pipeline_raw, str): - kwargs["pipeline_config"] = _resolve_existing_file(pipeline_raw) - - pipeline_config = PipelineConfig.from_kwargs(kwargs) + source = _resolve_existing_file(pipeline_raw) if isinstance(pipeline_raw, str) else pipeline_raw + pipeline_config = PipelineConfig.from_source(model_path, source) _apply_training_dit_arch_overrides(pipeline_config, dit_arch_overrides) _resolve_dit_quant_config(pipeline_config) return pipeline_config