From f18901b00b98cfdf23fa5b68e5a9d0cab4d46c2e Mon Sep 17 00:00:00 2001 From: SolitaryThinker Date: Sun, 28 Sep 2025 05:42:34 +0000 Subject: [PATCH] wip --- .buildkite/pipeline.yml | 24 +++++++++++--- .buildkite/scripts/pr_test.sh | 2 +- .github/workflows/pr-test.yml | 30 +++++++++++------- {fastvideo/tests => tests}/__init__.py | 0 {fastvideo/tests => tests}/conftest.py | 0 .../dataset/test_parquet_io.py | 0 .../dataset/test_schema_record_creator.py | 0 .../encoders/test_clip_encoder.py | 0 .../encoders/test_llama_encoder.py | 0 .../encoders/test_t5_encoder.py | 0 .../inference/STA/test_STA_inference.py | 0 ...llie style, golden era animation, clos.mp4 | Bin ...no lineart, blending, negative space, .mp4 | Bin .../lora/test_lora_inference_similarity.py | 3 +- .../inference/vmoba/test_vmoba_inference.py | 0 {fastvideo/tests => tests}/modal/pr_test.py | 24 +++++++------- .../nightly/i2v-wandb-summary.json | 0 ...deos_40_steps_900_581ff5eae2909d3a7b36.mp4 | Bin .../nightly/reference_video_1_sample_v0.mp4 | Bin .../nightly/test_e2e_dmd_t2v_crush_smol.py | 4 +-- .../test_e2e_i2v_overfit_single_sample.py | 4 +-- .../nightly/test_e2e_overfit_single_sample.py | 4 +-- .../old_tests/distributed_run.sh | 6 ++-- .../old_tests/test_t5_encoder.py | 0 .../tests => tests}/old_tests/test_wan_vae.py | 0 .../tests => tests}/old_tests/tp_example.py | 0 ... the vast horizon. The rugged landscap.mp4 | Bin ...ting with the energetic background of .mp4 | Bin ... the vast horizon. The rugged landscap.mp4 | Bin ...ting with the energetic background of .mp4 | Bin ... the darkness and depth of space reali.mp4 | Bin ... the darkness and depth of space reali.mp4 | Bin ... the vast horizon. The rugged landscap.mp4 | Bin ...ting with the energetic background of .mp4 | Bin ... the vast horizon. The rugged landscap.mp4 | Bin ...ting with the energetic background of .mp4 | Bin ...ting with the energetic background of .mp4 | Bin ...ting with the energetic background of .mp4 | Bin ...ting with the energetic background of .mp4 | Bin ... the darkness and depth of space reali.mp4 | Bin ... the darkness and depth of space reali.mp4 | Bin ...ting with the energetic background of .mp4 | Bin ...ting with the energetic background of .mp4 | Bin {fastvideo/tests => tests}/ssim/README.md | 2 +- .../ssim/test_causal_similarity.py | 2 +- .../ssim/test_inference_similarity.py | 2 +- .../ssim/update_reference_videos.sh | 0 .../stages/test_text_encoding.py | 0 .../VSA/reference_wandb_summary_VSA.json | 0 .../training/VSA/test_training_loss_VSA.py | 3 +- .../Vanilla/a40_reference_wandb_summary.json | 0 .../Vanilla/l40s_reference_wandb_summary.json | 0 .../training/Vanilla/test_training_loss.py | 5 +-- .../training/distill/test_distill_dmd.py | 0 .../l40s_reference_lora_wandb_summary.json | 0 .../training/lora/test_lora_training.py | 5 +-- .../transformers/test_hunyuanvideo.py | 0 .../transformers/test_hunyuanvideo_load.py | 0 .../transformers/test_wanvideo.py | 0 {fastvideo/tests => tests}/utils.py | 0 .../tests => tests}/vaes/test_hunyuan_vae.py | 0 .../vaes/test_official_wan_vae.py | 0 .../tests => tests}/vaes/test_wan_vae.py | 0 .../workflow/test_components_parquet_saver.py | 0 64 files changed, 72 insertions(+), 48 deletions(-) rename {fastvideo/tests => tests}/__init__.py (100%) rename {fastvideo/tests => tests}/conftest.py (100%) rename {fastvideo/tests => tests}/dataset/test_parquet_io.py (100%) rename {fastvideo/tests => tests}/dataset/test_schema_record_creator.py (100%) rename {fastvideo/tests => tests}/encoders/test_clip_encoder.py (100%) rename {fastvideo/tests => tests}/encoders/test_llama_encoder.py (100%) rename {fastvideo/tests => tests}/encoders/test_t5_encoder.py (100%) rename {fastvideo/tests => tests}/inference/STA/test_STA_inference.py (100%) rename {fastvideo/tests => tests}/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/steamboat-willie-1.3b_steamboat willie style, golden era animation, clos.mp4 (100%) rename {fastvideo/tests => tests}/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/wan-flat-color-1.3b-v2_flat color, no lineart, blending, negative space, .mp4 (100%) rename {fastvideo/tests => tests}/inference/lora/test_lora_inference_similarity.py (99%) rename {fastvideo/tests => tests}/inference/vmoba/test_vmoba_inference.py (100%) rename {fastvideo/tests => tests}/modal/pr_test.py (81%) rename {fastvideo/tests => tests}/nightly/i2v-wandb-summary.json (100%) rename {fastvideo/tests => tests}/nightly/i2v_validation_videos_40_steps_900_581ff5eae2909d3a7b36.mp4 (100%) rename {fastvideo/tests => tests}/nightly/reference_video_1_sample_v0.mp4 (100%) rename {fastvideo/tests => tests}/nightly/test_e2e_dmd_t2v_crush_smol.py (98%) rename {fastvideo/tests => tests}/nightly/test_e2e_i2v_overfit_single_sample.py (97%) rename {fastvideo/tests => tests}/nightly/test_e2e_overfit_single_sample.py (98%) rename {fastvideo/tests => tests}/old_tests/distributed_run.sh (50%) rename {fastvideo/tests => tests}/old_tests/test_t5_encoder.py (100%) rename {fastvideo/tests => tests}/old_tests/test_wan_vae.py (100%) rename {fastvideo/tests => tests}/old_tests/tp_example.py (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 (100%) rename {fastvideo/tests => tests}/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/SFWan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 (100%) rename {fastvideo/tests => tests}/ssim/README.md (93%) rename {fastvideo/tests => tests}/ssim/test_causal_similarity.py (98%) rename {fastvideo/tests => tests}/ssim/test_inference_similarity.py (99%) rename {fastvideo/tests => tests}/ssim/update_reference_videos.sh (100%) rename {fastvideo/tests => tests}/stages/test_text_encoding.py (100%) rename {fastvideo/tests => tests}/training/VSA/reference_wandb_summary_VSA.json (100%) rename {fastvideo/tests => tests}/training/VSA/test_training_loss_VSA.py (97%) rename {fastvideo/tests => tests}/training/Vanilla/a40_reference_wandb_summary.json (100%) rename {fastvideo/tests => tests}/training/Vanilla/l40s_reference_wandb_summary.json (100%) rename {fastvideo/tests => tests}/training/Vanilla/test_training_loss.py (95%) rename {fastvideo/tests => tests}/training/distill/test_distill_dmd.py (100%) rename {fastvideo/tests => tests}/training/lora/l40s_reference_lora_wandb_summary.json (100%) rename {fastvideo/tests => tests}/training/lora/test_lora_training.py (96%) rename {fastvideo/tests => tests}/transformers/test_hunyuanvideo.py (100%) rename {fastvideo/tests => tests}/transformers/test_hunyuanvideo_load.py (100%) rename {fastvideo/tests => tests}/transformers/test_wanvideo.py (100%) rename {fastvideo/tests => tests}/utils.py (100%) rename {fastvideo/tests => tests}/vaes/test_hunyuan_vae.py (100%) rename {fastvideo/tests => tests}/vaes/test_official_wan_vae.py (100%) rename {fastvideo/tests => tests}/vaes/test_wan_vae.py (100%) rename {fastvideo/tests => tests}/workflow/test_components_parquet_saver.py (100%) diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml index 11fef275d..f343c66e7 100644 --- a/.buildkite/pipeline.yml +++ b/.buildkite/pipeline.yml @@ -18,7 +18,8 @@ steps: - path: - "fastvideo/models/encoders/**" - "fastvideo/models/loader/**" - - "fastvideo/tests/encoders/**" + - "tests/encoders/**" + - "tests/utils.py" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -31,7 +32,8 @@ steps: - path: - "fastvideo/models/vaes/**" - "fastvideo/models/loader/**" - - "fastvideo/tests/vaes/**" + - "tests/vaes/**" + - "tests/utils.py" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -44,7 +46,8 @@ steps: - path: - "fastvideo/models/dits/**" - "fastvideo/models/loader/**" - - "fastvideo/tests/transformers/**" + - "tests/transformers/**" + - "tests/utils.py" - "fastvideo/layers/**" - "fastvideo/attention/**" - "pyproject.toml" @@ -58,6 +61,8 @@ steps: queue: "default" - path: - "fastvideo/**/*.py" + - "tests/ssim/**" + - "tests/utils.py" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -68,9 +73,10 @@ steps: agents: queue: "default" - path: - - "fastvideo/tests/lora/**" + - "tests/inference/lora/**" - "fastvideo/models/loader/**" - - "fastvideo/tests/transformers/**" + - "tests/transformers/**" + - "tests/utils.py" - "fastvideo/pipelines/**" - "fastvideo/layers/lora/**" - "pyproject.toml" @@ -84,6 +90,7 @@ steps: queue: "default" - path: - "fastvideo/**" + - "tests/training/Vanilla/**" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -95,6 +102,7 @@ steps: queue: "default" - path: - "fastvideo/training/*distillation_pipeline.py" + - "tests/training/distill/**" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -106,6 +114,7 @@ steps: queue: "default" - path: - "fastvideo/**" + - "tests/training/lora/**" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -117,6 +126,7 @@ steps: queue: "default" - path: - "fastvideo/**" + - "tests/training/VSA/**" - "csrc/attn/video_sparse_attn/**" - "csrc/attn/video_sparse_attn/tk/**" - "csrc/attn/video_sparse_attn/setup.py" @@ -133,6 +143,7 @@ steps: queue: "default" - path: - "fastvideo/**" + - "tests/inference/STA/**" - "csrc/attn/sliding_tile_attn/**" - "csrc/attn/sliding_tile_attn/setup.py" - "csrc/attn/sliding_tile_attn/config_sta.py" @@ -190,6 +201,7 @@ steps: - path: - "csrc/attn/vmoba_attn/vmoba/**" - "fastvideo/attention/backends/vmoba.py" + - "tests/inference/vmoba/**" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: @@ -201,6 +213,8 @@ steps: queue: "default" - path: - "fastvideo/**" + - "tests/dataset/**" + - "tests/workflow/**" - "pyproject.toml" - "docker/Dockerfile.python3.12" config: diff --git a/.buildkite/scripts/pr_test.sh b/.buildkite/scripts/pr_test.sh index aa42f4936..fb12a7889 100755 --- a/.buildkite/scripts/pr_test.sh +++ b/.buildkite/scripts/pr_test.sh @@ -50,7 +50,7 @@ else exit 1 fi -MODAL_TEST_FILE="fastvideo/tests/modal/pr_test.py" +MODAL_TEST_FILE="tests/modal/pr_test.py" if [ -z "${TEST_TYPE:-}" ]; then log "Error: TEST_TYPE environment variable is not set" diff --git a/.github/workflows/pr-test.yml b/.github/workflows/pr-test.yml index cf28eb3dc..618f15253 100644 --- a/.github/workflows/pr-test.yml +++ b/.github/workflows/pr-test.yml @@ -127,29 +127,35 @@ jobs: encoder-test: - 'fastvideo/models/encoders/**' - 'fastvideo/models/loader/**' - - 'fastvideo/tests/encoders/**' + - 'tests/encoders/**' + - 'tests/utils.py' - *common-paths vae-test: - 'fastvideo/models/vaes/**' - 'fastvideo/models/loader/**' - - 'fastvideo/tests/vaes/**' + - 'tests/vaes/**' + - 'tests/utils.py' - *common-paths transformer-test: - 'fastvideo/models/dits/**' - 'fastvideo/models/loader/**' - - 'fastvideo/tests/transformers/**' + - 'tests/transformers/**' + - 'tests/utils.py' - 'fastvideo/layers/**' - 'fastvideo/attention/**' - *common-paths training-test: - 'fastvideo/**' + - 'tests/training/Vanilla/**' - *common-paths training-test-VSA: - 'fastvideo/**' + - 'tests/training/VSA/**' - *common-paths - *vsa-kernel-paths inference-test-STA: - 'fastvideo/**' + - 'tests/inference/STA/**' - *common-paths - *sta-kernel-paths precision-test-STA: @@ -160,6 +166,8 @@ jobs: - *vsa-kernel-paths unit-test: - 'fastvideo/**' + - 'tests/dataset/**' + - 'tests/workflow/**' - *common-paths encoder-test: @@ -174,7 +182,7 @@ jobs: gpu_count: 1 volume_size: 100 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - test_command: "uv pip install -e .[test] && pytest ./fastvideo/tests/encoders -s" + test_command: "uv pip install -e .[test] && pytest ./tests/encoders -s" timeout_minutes: 30 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -192,7 +200,7 @@ jobs: gpu_count: 1 volume_size: 100 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - test_command: "uv pip install -e .[test] && pytest ./fastvideo/tests/vaes -s" + test_command: "uv pip install -e .[test] && pytest ./tests/vaes -s" timeout_minutes: 30 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -210,7 +218,7 @@ jobs: gpu_count: 1 volume_size: 100 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - test_command: "uv pip install -e .[test] && pytest ./fastvideo/tests/transformers -s" + test_command: "uv pip install -e .[test] && pytest ./tests/transformers -s" timeout_minutes: 30 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -236,7 +244,7 @@ jobs: volume_size: 200 disk_size: 200 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:${{ matrix.python-version.tag }}" - test_command: "uv pip install -e .[test] && pytest ./fastvideo/tests/ssim -vs" + test_command: "uv pip install -e .[test] && pytest ./tests/ssim -vs" timeout_minutes: 60 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -255,7 +263,7 @@ jobs: volume_size: 100 disk_size: 100 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - test_command: "wandb login $WANDB_API_KEY && uv pip install -e .[test] && pytest ./fastvideo/tests/training/Vanilla -srP" + test_command: "wandb login $WANDB_API_KEY && uv pip install -e .[test] && pytest ./tests/training/Vanilla -srP" timeout_minutes: 30 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -275,7 +283,7 @@ jobs: volume_size: 100 disk_size: 100 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - test_command: "wandb login $WANDB_API_KEY && uv pip install -e .[test] && pytest ./fastvideo/tests/training/VSA -srP" + test_command: "wandb login $WANDB_API_KEY && uv pip install -e .[test] && pytest ./tests/training/VSA -srP" timeout_minutes: 30 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -295,7 +303,7 @@ jobs: volume_size: 100 disk_size: 100 image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - test_command: "uv pip install -e .[test] && pytest ./fastvideo/tests/inference/STA -srP" + test_command: "uv pip install -e .[test] && pytest ./tests/inference/STA -srP" timeout_minutes: 30 secrets: RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} @@ -369,7 +377,7 @@ jobs: # volume_size: 100 # disk_size: 100 # image: "ghcr.io/${{ github.repository }}/fastvideo-dev:py3.12-latest" - # test_command: "wandb login $WANDB_API_KEY && uv pip install -e .[test] && pytest ./fastvideo/tests/nightly/test_e2e_overfit_single_sample.py -vs" +# test_command: "wandb login $WANDB_API_KEY && uv pip install -e .[test] && pytest ./tests/nightly/test_e2e_overfit_single_sample.py -vs" # timeout_minutes: 30 # secrets: # RUNPOD_API_KEY: ${{ secrets.RUNPOD_API_KEY }} diff --git a/fastvideo/tests/__init__.py b/tests/__init__.py similarity index 100% rename from fastvideo/tests/__init__.py rename to tests/__init__.py diff --git a/fastvideo/tests/conftest.py b/tests/conftest.py similarity index 100% rename from fastvideo/tests/conftest.py rename to tests/conftest.py diff --git a/fastvideo/tests/dataset/test_parquet_io.py b/tests/dataset/test_parquet_io.py similarity index 100% rename from fastvideo/tests/dataset/test_parquet_io.py rename to tests/dataset/test_parquet_io.py diff --git a/fastvideo/tests/dataset/test_schema_record_creator.py b/tests/dataset/test_schema_record_creator.py similarity index 100% rename from fastvideo/tests/dataset/test_schema_record_creator.py rename to tests/dataset/test_schema_record_creator.py diff --git a/fastvideo/tests/encoders/test_clip_encoder.py b/tests/encoders/test_clip_encoder.py similarity index 100% rename from fastvideo/tests/encoders/test_clip_encoder.py rename to tests/encoders/test_clip_encoder.py diff --git a/fastvideo/tests/encoders/test_llama_encoder.py b/tests/encoders/test_llama_encoder.py similarity index 100% rename from fastvideo/tests/encoders/test_llama_encoder.py rename to tests/encoders/test_llama_encoder.py diff --git a/fastvideo/tests/encoders/test_t5_encoder.py b/tests/encoders/test_t5_encoder.py similarity index 100% rename from fastvideo/tests/encoders/test_t5_encoder.py rename to tests/encoders/test_t5_encoder.py diff --git a/fastvideo/tests/inference/STA/test_STA_inference.py b/tests/inference/STA/test_STA_inference.py similarity index 100% rename from fastvideo/tests/inference/STA/test_STA_inference.py rename to tests/inference/STA/test_STA_inference.py diff --git a/fastvideo/tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/steamboat-willie-1.3b_steamboat willie style, golden era animation, clos.mp4 b/tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/steamboat-willie-1.3b_steamboat willie style, golden era animation, clos.mp4 similarity index 100% rename from fastvideo/tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/steamboat-willie-1.3b_steamboat willie style, golden era animation, clos.mp4 rename to tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/steamboat-willie-1.3b_steamboat willie style, golden era animation, clos.mp4 diff --git a/fastvideo/tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/wan-flat-color-1.3b-v2_flat color, no lineart, blending, negative space, .mp4 b/tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/wan-flat-color-1.3b-v2_flat color, no lineart, blending, negative space, .mp4 similarity index 100% rename from fastvideo/tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/wan-flat-color-1.3b-v2_flat color, no lineart, blending, negative space, .mp4 rename to tests/inference/lora/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/wan-flat-color-1.3b-v2_flat color, no lineart, blending, negative space, .mp4 diff --git a/fastvideo/tests/inference/lora/test_lora_inference_similarity.py b/tests/inference/lora/test_lora_inference_similarity.py similarity index 99% rename from fastvideo/tests/inference/lora/test_lora_inference_similarity.py rename to tests/inference/lora/test_lora_inference_similarity.py index 2033e7903..736bdf790 100644 --- a/fastvideo/tests/inference/lora/test_lora_inference_similarity.py +++ b/tests/inference/lora/test_lora_inference_similarity.py @@ -6,7 +6,7 @@ import pytest from fastvideo import VideoGenerator from fastvideo.logger import init_logger -from fastvideo.tests.utils import compute_video_ssim_torchvision, write_ssim_results +from tests.utils import compute_video_ssim_torchvision, write_ssim_results from diffusers import DiffusionPipeline from fastvideo.fastvideo_args import FastVideoArgs from fastvideo.pipelines import build_pipeline @@ -192,4 +192,3 @@ def test_lora_inference_similarity(ATTENTION_BACKEND, model_id): - diff --git a/fastvideo/tests/inference/vmoba/test_vmoba_inference.py b/tests/inference/vmoba/test_vmoba_inference.py similarity index 100% rename from fastvideo/tests/inference/vmoba/test_vmoba_inference.py rename to tests/inference/vmoba/test_vmoba_inference.py diff --git a/fastvideo/tests/modal/pr_test.py b/tests/modal/pr_test.py similarity index 81% rename from fastvideo/tests/modal/pr_test.py rename to tests/modal/pr_test.py index f75e2a963..2622dbf61 100644 --- a/fastvideo/tests/modal/pr_test.py +++ b/tests/modal/pr_test.py @@ -64,35 +64,35 @@ def run_test(pytest_command: str): @app.function(gpu="L40S:1", image=image, timeout=900) def run_encoder_tests(): - run_test("pytest ./fastvideo/tests/encoders -vs") + run_test("pytest ./tests/encoders -vs") @app.function(gpu="L40S:1", image=image, timeout=900) def run_vae_tests(): - run_test("pytest ./fastvideo/tests/vaes -vs") + run_test("pytest ./tests/vaes -vs") @app.function(gpu="L40S:1", image=image, timeout=900) def run_transformer_tests(): - run_test("pytest ./fastvideo/tests/transformers -vs") + run_test("pytest ./tests/transformers -vs") @app.function(gpu="L40S:2", image=image, timeout=2700) def run_ssim_tests(): - run_test("pytest ./fastvideo/tests/ssim -vs") + run_test("pytest ./tests/ssim -vs") @app.function(gpu="L40S:4", image=image, timeout=900, secrets=[modal.Secret.from_dict({"WANDB_API_KEY": os.environ.get("WANDB_API_KEY", "")})]) def run_training_tests(): - run_test("wandb login $WANDB_API_KEY && pytest ./fastvideo/tests/training/Vanilla -srP") + run_test("wandb login $WANDB_API_KEY && pytest ./tests/training/Vanilla -srP") @app.function(gpu="L40S:2", image=image, timeout=900, secrets=[modal.Secret.from_dict({"WANDB_API_KEY": os.environ.get("WANDB_API_KEY", "")})]) def run_training_lora_tests(): - run_test("wandb login $WANDB_API_KEY && pytest ./fastvideo/tests/training/lora/test_lora_training.py -srP") + run_test("wandb login $WANDB_API_KEY && pytest ./tests/training/lora/test_lora_training.py -srP") @app.function(gpu="H100:2", image=image, timeout=900, secrets=[modal.Secret.from_dict({"WANDB_API_KEY": os.environ.get("WANDB_API_KEY", "")})]) def run_training_tests_VSA(): - run_test("wandb login $WANDB_API_KEY && pytest ./fastvideo/tests/training/VSA -srP") + run_test("wandb login $WANDB_API_KEY && pytest ./tests/training/VSA -srP") @app.function(gpu="H100:2", image=image, timeout=900) def run_inference_tests_STA(): - run_test("pytest ./fastvideo/tests/inference/STA -srP") + run_test("pytest ./tests/inference/STA -srP") @app.function(gpu="H100:1", image=image, timeout=900) def run_precision_tests_STA(): @@ -108,16 +108,16 @@ def run_precision_tests_vmoba(): @app.function(gpu="L40S:1", image=image, timeout=900) def run_inference_tests_vmoba(): - run_test('python fastvideo/tests/inference/vmoba/test_vmoba_inference.py') + run_test('python tests/inference/vmoba/test_vmoba_inference.py') @app.function(gpu="L40S:1", image=image, timeout=3600) def run_inference_lora_tests(): - run_test("pytest ./fastvideo/tests/inference/lora/test_lora_inference_similarity.py -vs") + run_test("pytest ./tests/inference/lora/test_lora_inference_similarity.py -vs") @app.function(gpu="L40S:2", image=image, timeout=900) def run_distill_dmd_tests(): - run_test("pytest ./fastvideo/tests/training/distill/test_distill_dmd.py -vs") + run_test("pytest ./tests/training/distill/test_distill_dmd.py -vs") @app.function(gpu="L40S:1", image=image, timeout=900) def run_unit_test(): - run_test("pytest ./fastvideo/tests/dataset/ ./fastvideo/tests/workflow/ -vs") + run_test("pytest ./tests/dataset/ ./tests/workflow/ -vs") diff --git a/fastvideo/tests/nightly/i2v-wandb-summary.json b/tests/nightly/i2v-wandb-summary.json similarity index 100% rename from fastvideo/tests/nightly/i2v-wandb-summary.json rename to tests/nightly/i2v-wandb-summary.json diff --git a/fastvideo/tests/nightly/i2v_validation_videos_40_steps_900_581ff5eae2909d3a7b36.mp4 b/tests/nightly/i2v_validation_videos_40_steps_900_581ff5eae2909d3a7b36.mp4 similarity index 100% rename from fastvideo/tests/nightly/i2v_validation_videos_40_steps_900_581ff5eae2909d3a7b36.mp4 rename to tests/nightly/i2v_validation_videos_40_steps_900_581ff5eae2909d3a7b36.mp4 diff --git a/fastvideo/tests/nightly/reference_video_1_sample_v0.mp4 b/tests/nightly/reference_video_1_sample_v0.mp4 similarity index 100% rename from fastvideo/tests/nightly/reference_video_1_sample_v0.mp4 rename to tests/nightly/reference_video_1_sample_v0.mp4 diff --git a/fastvideo/tests/nightly/test_e2e_dmd_t2v_crush_smol.py b/tests/nightly/test_e2e_dmd_t2v_crush_smol.py similarity index 98% rename from fastvideo/tests/nightly/test_e2e_dmd_t2v_crush_smol.py rename to tests/nightly/test_e2e_dmd_t2v_crush_smol.py index 64c6cd59c..44ae59460 100644 --- a/fastvideo/tests/nightly/test_e2e_dmd_t2v_crush_smol.py +++ b/tests/nightly/test_e2e_dmd_t2v_crush_smol.py @@ -3,7 +3,7 @@ from pathlib import Path from huggingface_hub import snapshot_download import subprocess import sys -from fastvideo.tests.ssim.test_inference_similarity import compute_video_ssim_torchvision +from tests.ssim.test_inference_similarity import compute_video_ssim_torchvision import shutil # Import the training pipeline @@ -181,4 +181,4 @@ def test_e2e_overfit_single_sample(): if __name__ == "__main__": - test_e2e_overfit_single_sample() \ No newline at end of file + test_e2e_overfit_single_sample() diff --git a/fastvideo/tests/nightly/test_e2e_i2v_overfit_single_sample.py b/tests/nightly/test_e2e_i2v_overfit_single_sample.py similarity index 97% rename from fastvideo/tests/nightly/test_e2e_i2v_overfit_single_sample.py rename to tests/nightly/test_e2e_i2v_overfit_single_sample.py index 3a1177a6f..721b1cdaa 100644 --- a/fastvideo/tests/nightly/test_e2e_i2v_overfit_single_sample.py +++ b/tests/nightly/test_e2e_i2v_overfit_single_sample.py @@ -4,7 +4,7 @@ from huggingface_hub import snapshot_download import shutil import subprocess import sys -from fastvideo.tests.ssim.test_inference_similarity import compute_video_ssim_torchvision +from tests.ssim.test_inference_similarity import compute_video_ssim_torchvision # Import the training pipeline sys.path.append(str(Path(__file__).parent.parent.parent.parent.parent)) @@ -169,4 +169,4 @@ def test_e2e_overfit_single_sample(): if __name__ == "__main__": - test_e2e_overfit_single_sample() \ No newline at end of file + test_e2e_overfit_single_sample() diff --git a/fastvideo/tests/nightly/test_e2e_overfit_single_sample.py b/tests/nightly/test_e2e_overfit_single_sample.py similarity index 98% rename from fastvideo/tests/nightly/test_e2e_overfit_single_sample.py rename to tests/nightly/test_e2e_overfit_single_sample.py index 3a3eddfcb..8f46fb208 100644 --- a/fastvideo/tests/nightly/test_e2e_overfit_single_sample.py +++ b/tests/nightly/test_e2e_overfit_single_sample.py @@ -4,7 +4,7 @@ from huggingface_hub import snapshot_download import shutil import subprocess import sys -from fastvideo.tests.ssim.test_inference_similarity import compute_video_ssim_torchvision +from tests.ssim.test_inference_similarity import compute_video_ssim_torchvision # Import the training pipeline sys.path.append(str(Path(__file__).parent.parent.parent.parent.parent)) @@ -174,4 +174,4 @@ def test_e2e_overfit_single_sample(): if __name__ == "__main__": - test_e2e_overfit_single_sample() \ No newline at end of file + test_e2e_overfit_single_sample() diff --git a/fastvideo/tests/old_tests/distributed_run.sh b/tests/old_tests/distributed_run.sh similarity index 50% rename from fastvideo/tests/old_tests/distributed_run.sh rename to tests/old_tests/distributed_run.sh index 6c2ee410e..479312afb 100644 --- a/fastvideo/tests/old_tests/distributed_run.sh +++ b/tests/old_tests/distributed_run.sh @@ -10,10 +10,10 @@ torchrun --standalone --nnodes=1 --nproc_per_node=$num_gpus \ num_gpus=2 torchrun --standalone --nnodes=1 --nproc_per_node=$num_gpus \ --master_port 29503 \ - fastvideo/tests/test_hunyuanvideo_load.py --sequence_model_parallel_size $num_gpus + tests/test_hunyuanvideo_load.py --sequence_model_parallel_size $num_gpus -torchrun --nnodes=1 --nproc_per_node=1 --master_port 29503 fastvideo/tests/test_llama_encoder.py +torchrun --nnodes=1 --nproc_per_node=1 --master_port 29503 tests/test_llama_encoder.py export FASTVIDEO_ATTENTION_BACKEND=FLASH_ATTN -torchrun --nnodes=1 --nproc_per_node=1 --master_port 29503 fastvideo/tests/test_clip_encoder.py \ No newline at end of file +torchrun --nnodes=1 --nproc_per_node=1 --master_port 29503 tests/test_clip_encoder.py diff --git a/fastvideo/tests/old_tests/test_t5_encoder.py b/tests/old_tests/test_t5_encoder.py similarity index 100% rename from fastvideo/tests/old_tests/test_t5_encoder.py rename to tests/old_tests/test_t5_encoder.py diff --git a/fastvideo/tests/old_tests/test_wan_vae.py b/tests/old_tests/test_wan_vae.py similarity index 100% rename from fastvideo/tests/old_tests/test_wan_vae.py rename to tests/old_tests/test_wan_vae.py diff --git a/fastvideo/tests/old_tests/tp_example.py b/tests/old_tests/tp_example.py similarity index 100% rename from fastvideo/tests/old_tests/tp_example.py rename to tests/old_tests/tp_example.py diff --git a/fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 b/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 rename to tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/A40_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 b/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 rename to tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/A40_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 b/tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 rename to tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 b/tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 rename to tests/ssim/A40_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 b/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 rename to tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 b/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 rename to tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/A lone hiker stands atop a towering cliff, silhouetted against the vast horizon. The rugged landscap.mp4 diff --git a/fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/A40_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/L40S_reference_videos/FastHunyuan-diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/SFWan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/L40S_reference_videos/SFWan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/SFWan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/L40S_reference_videos/SFWan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 b/tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 rename to tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/FLASH_ATTN/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 b/tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 rename to tests/ssim/L40S_reference_videos/Wan2.1-I2V-14B-480P-Diffusers/TORCH_SDPA/An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space reali.mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/FLASH_ATTN/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 b/tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 similarity index 100% rename from fastvideo/tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 rename to tests/ssim/L40S_reference_videos/Wan2.1-T2V-1.3B-Diffusers/TORCH_SDPA/Will Smith casually eats noodles, his relaxed demeanor contrasting with the energetic background of .mp4 diff --git a/fastvideo/tests/ssim/README.md b/tests/ssim/README.md similarity index 93% rename from fastvideo/tests/ssim/README.md rename to tests/ssim/README.md index 61c942103..5efec5b6c 100644 --- a/fastvideo/tests/ssim/README.md +++ b/tests/ssim/README.md @@ -2,7 +2,7 @@ The reference videos in the `*_reference_videos` directory are used as part of a `A40_reference_videos` are generated on A40s and so on. -run `bash update_reference_videos.sh` from inside the `fastvideo/tests/ssim/` directory after running `test_inference_similarity.py` to update reference videos. Note: make sure to update the path to the corresponding device. +run `bash update_reference_videos.sh` from inside the `tests/ssim/` directory after running `test_inference_similarity.py` to update reference videos. Note: make sure to update the path to the corresponding device. reference videos were generated on commit `4aeabbc629e0edf91477e80e795e7bb1823c71cb` causal videos were generated on commit b318063c0a4618f1d5d99ea82ca67a06aad0d19d diff --git a/fastvideo/tests/ssim/test_causal_similarity.py b/tests/ssim/test_causal_similarity.py similarity index 98% rename from fastvideo/tests/ssim/test_causal_similarity.py rename to tests/ssim/test_causal_similarity.py index 3154873cc..11a052558 100644 --- a/fastvideo/tests/ssim/test_causal_similarity.py +++ b/tests/ssim/test_causal_similarity.py @@ -7,7 +7,7 @@ import pytest from fastvideo import VideoGenerator from fastvideo.logger import init_logger -from fastvideo.tests.utils import compute_video_ssim_torchvision, write_ssim_results +from tests.utils import compute_video_ssim_torchvision, write_ssim_results from fastvideo.worker.multiproc_executor import MultiprocExecutor logger = init_logger(__name__) diff --git a/fastvideo/tests/ssim/test_inference_similarity.py b/tests/ssim/test_inference_similarity.py similarity index 99% rename from fastvideo/tests/ssim/test_inference_similarity.py rename to tests/ssim/test_inference_similarity.py index 608586897..7dffd4c69 100644 --- a/fastvideo/tests/ssim/test_inference_similarity.py +++ b/tests/ssim/test_inference_similarity.py @@ -7,7 +7,7 @@ import pytest from fastvideo import VideoGenerator from fastvideo.logger import init_logger -from fastvideo.tests.utils import compute_video_ssim_torchvision, write_ssim_results +from tests.utils import compute_video_ssim_torchvision, write_ssim_results from fastvideo.worker.multiproc_executor import MultiprocExecutor logger = init_logger(__name__) diff --git a/fastvideo/tests/ssim/update_reference_videos.sh b/tests/ssim/update_reference_videos.sh similarity index 100% rename from fastvideo/tests/ssim/update_reference_videos.sh rename to tests/ssim/update_reference_videos.sh diff --git a/fastvideo/tests/stages/test_text_encoding.py b/tests/stages/test_text_encoding.py similarity index 100% rename from fastvideo/tests/stages/test_text_encoding.py rename to tests/stages/test_text_encoding.py diff --git a/fastvideo/tests/training/VSA/reference_wandb_summary_VSA.json b/tests/training/VSA/reference_wandb_summary_VSA.json similarity index 100% rename from fastvideo/tests/training/VSA/reference_wandb_summary_VSA.json rename to tests/training/VSA/reference_wandb_summary_VSA.json diff --git a/fastvideo/tests/training/VSA/test_training_loss_VSA.py b/tests/training/VSA/test_training_loss_VSA.py similarity index 97% rename from fastvideo/tests/training/VSA/test_training_loss_VSA.py rename to tests/training/VSA/test_training_loss_VSA.py index 5744e81d4..c00f00bf3 100644 --- a/fastvideo/tests/training/VSA/test_training_loss_VSA.py +++ b/tests/training/VSA/test_training_loss_VSA.py @@ -12,7 +12,8 @@ from fastvideo.fastvideo_args import FastVideoArgs, TrainingArgs from fastvideo.utils import FlexibleArgumentParser wandb_name = "test_training_loss_VSA" -reference_wandb_summary_file = "fastvideo/tests/training/VSA/reference_wandb_summary_VSA.json" +_REFERENCE_DIR = Path(__file__).resolve().parent +reference_wandb_summary_file = str(_REFERENCE_DIR / "reference_wandb_summary_VSA.json") NUM_NODES = "1" NUM_GPUS_PER_NODE = "2" diff --git a/fastvideo/tests/training/Vanilla/a40_reference_wandb_summary.json b/tests/training/Vanilla/a40_reference_wandb_summary.json similarity index 100% rename from fastvideo/tests/training/Vanilla/a40_reference_wandb_summary.json rename to tests/training/Vanilla/a40_reference_wandb_summary.json diff --git a/fastvideo/tests/training/Vanilla/l40s_reference_wandb_summary.json b/tests/training/Vanilla/l40s_reference_wandb_summary.json similarity index 100% rename from fastvideo/tests/training/Vanilla/l40s_reference_wandb_summary.json rename to tests/training/Vanilla/l40s_reference_wandb_summary.json diff --git a/fastvideo/tests/training/Vanilla/test_training_loss.py b/tests/training/Vanilla/test_training_loss.py similarity index 95% rename from fastvideo/tests/training/Vanilla/test_training_loss.py rename to tests/training/Vanilla/test_training_loss.py index de0b92f21..a21f98097 100644 --- a/fastvideo/tests/training/Vanilla/test_training_loss.py +++ b/tests/training/Vanilla/test_training_loss.py @@ -16,8 +16,9 @@ from fastvideo.utils import FlexibleArgumentParser from fastvideo.training.wan_training_pipeline import WanTrainingPipeline wandb_name = "test_training_loss" -a40_reference_wandb_summary_file = "fastvideo/tests/training/Vanilla/a40_reference_wandb_summary.json" -l40s_reference_wandb_summary_file = "fastvideo/tests/training/Vanilla/l40s_reference_wandb_summary.json" +_REFERENCE_DIR = Path(__file__).resolve().parent +a40_reference_wandb_summary_file = str(_REFERENCE_DIR / "a40_reference_wandb_summary.json") +l40s_reference_wandb_summary_file = str(_REFERENCE_DIR / "l40s_reference_wandb_summary.json") NUM_NODES = "1" NUM_GPUS_PER_NODE = "2" diff --git a/fastvideo/tests/training/distill/test_distill_dmd.py b/tests/training/distill/test_distill_dmd.py similarity index 100% rename from fastvideo/tests/training/distill/test_distill_dmd.py rename to tests/training/distill/test_distill_dmd.py diff --git a/fastvideo/tests/training/lora/l40s_reference_lora_wandb_summary.json b/tests/training/lora/l40s_reference_lora_wandb_summary.json similarity index 100% rename from fastvideo/tests/training/lora/l40s_reference_lora_wandb_summary.json rename to tests/training/lora/l40s_reference_lora_wandb_summary.json diff --git a/fastvideo/tests/training/lora/test_lora_training.py b/tests/training/lora/test_lora_training.py similarity index 96% rename from fastvideo/tests/training/lora/test_lora_training.py rename to tests/training/lora/test_lora_training.py index 50b8d4165..c85e0073c 100644 --- a/fastvideo/tests/training/lora/test_lora_training.py +++ b/tests/training/lora/test_lora_training.py @@ -9,7 +9,8 @@ import json from huggingface_hub import snapshot_download wandb_name = "test_lora_training" -l40s_reference_wandb_summary_file = "fastvideo/tests/training/lora/l40s_reference_lora_wandb_summary.json" +_REFERENCE_DIR = Path(__file__).resolve().parent +l40s_reference_wandb_summary_file = str(_REFERENCE_DIR / "l40s_reference_lora_wandb_summary.json") NUM_NODES = "1" NUM_GPUS_PER_NODE = "2" @@ -116,4 +117,4 @@ def test_lora_training(): if __name__ == "__main__": - test_lora_training() \ No newline at end of file + test_lora_training() diff --git a/fastvideo/tests/transformers/test_hunyuanvideo.py b/tests/transformers/test_hunyuanvideo.py similarity index 100% rename from fastvideo/tests/transformers/test_hunyuanvideo.py rename to tests/transformers/test_hunyuanvideo.py diff --git a/fastvideo/tests/transformers/test_hunyuanvideo_load.py b/tests/transformers/test_hunyuanvideo_load.py similarity index 100% rename from fastvideo/tests/transformers/test_hunyuanvideo_load.py rename to tests/transformers/test_hunyuanvideo_load.py diff --git a/fastvideo/tests/transformers/test_wanvideo.py b/tests/transformers/test_wanvideo.py similarity index 100% rename from fastvideo/tests/transformers/test_wanvideo.py rename to tests/transformers/test_wanvideo.py diff --git a/fastvideo/tests/utils.py b/tests/utils.py similarity index 100% rename from fastvideo/tests/utils.py rename to tests/utils.py diff --git a/fastvideo/tests/vaes/test_hunyuan_vae.py b/tests/vaes/test_hunyuan_vae.py similarity index 100% rename from fastvideo/tests/vaes/test_hunyuan_vae.py rename to tests/vaes/test_hunyuan_vae.py diff --git a/fastvideo/tests/vaes/test_official_wan_vae.py b/tests/vaes/test_official_wan_vae.py similarity index 100% rename from fastvideo/tests/vaes/test_official_wan_vae.py rename to tests/vaes/test_official_wan_vae.py diff --git a/fastvideo/tests/vaes/test_wan_vae.py b/tests/vaes/test_wan_vae.py similarity index 100% rename from fastvideo/tests/vaes/test_wan_vae.py rename to tests/vaes/test_wan_vae.py diff --git a/fastvideo/tests/workflow/test_components_parquet_saver.py b/tests/workflow/test_components_parquet_saver.py similarity index 100% rename from fastvideo/tests/workflow/test_components_parquet_saver.py rename to tests/workflow/test_components_parquet_saver.py