[misc]: Refactor separate training pipeline runner - #1696
Conversation
There was a problem hiding this comment.
Welcome to FastVideo! Thanks for your first pull request.
How our CI works:
PRs run a two-tier CI system:
- Pre-commit — formatting (yapf), linting (ruff), type checking (mypy). Runs immediately on every PR.
- Fastcheck — core GPU tests (encoders, VAEs, transformers, kernels, unit tests). Runs automatically via Buildkite on relevant file changes (~10-15 min).
- Full Suite — integration tests, training pipelines, SSIM regression. Runs only when a reviewer adds the
readylabel.
Before your PR is reviewed:
-
pre-commit run --all-filespasses locally - You've added or updated tests for your changes
- The PR description explains what and why
If pre-commit fails, a bot comment will explain how to fix it. Fastcheck and Full Suite results appear in the Checks section below.
Useful links:
Merge Protections🔴 1 of 1 protections blocking · waiting on 👀 reviews and 🤖 CI
🔴 PR merge requirementsWaiting for
This rule is failing.
|
9cfcace to
53ceb6e
Compare
|
Thanks for the contribution! This refactor makes sense. However, are many training scripts in the repo that invoke these pipeline files directly. Removing the existing entry points would break downstream compatibility. Could you keep backward-compatible entry points and update the in-repo scripts to use the new runner as well? |
7d14ccb to
f48b81d
Compare
Pre-commit checks failedHi @techverve, the pre-commit checks have failed. To fix them locally: # Install pre-commit if you haven't already
uv pip install pre-commit
pre-commit install
# Run all checks and auto-fix what's possible
pre-commit run --all-filesCommon fixes:
After fixing, commit and push the changes. The checks will re-run automatically. For future commits, |
105e034 to
6ed353f
Compare
Hi @H1yori233 , I have addressed your suggestions could you please have a look again. |
…ynamic instantiation
…r and fix distillation scripts
abd05e0 to
db01f15
Compare
|
Thx, LGTM now. |
What
Decoupled the CLI execution logic from the legacy training pipelines by introducing a centralized runner script (
fastvideo/training/runner.py).Why
To enforce separation of concerns and improve code maintainability. Previously, the legacy training pipelines coupled the class definitions directly with the script execution entry points. This architectural pattern resulted in redundant boilerplate across the codebase and made the pipeline modules harder to test and import in isolation.
How
main()execution blocks and CLI argument parsing out of the individual pipeline modules.runner.pyentry point that usesimportlibto dynamically load the target pipeline at runtime via--pipeline_classand--pipeline_moduleflags.finetuneanddistillshell scripts to target the new unified runner.MERGE WORKFLOW:
ON-DEMAND TESTING (write access required):
/test full — Full Test Suite /test ssim — SSIM regression
/test training — Training pipeline /test encoder — Encoder tests
/test transformer — Transformer tests /test vae — VAE tests
/test kernel — CUDA kernel tests /test unit — Unit tests
See docs/contributing/pull_requests.md for all 17 test commands
Purpose
Fixes https://linear.app/fastvideo/issue/FAS-215/training-separate-trainingpipeline-class-definition-and-runner-script
Checklist
pre-commit run --all-filesand fixed all issuesFor model/pipeline changes, also check: