From 8f5712629f1950efd8ab9ecbd2a1efc2f828bfc2 Mon Sep 17 00:00:00 2001 From: Mihir Jagtap <94254893+MihirJagtap@users.noreply.github.com> Date: Tue, 4 Nov 2025 14:31:56 -0800 Subject: [PATCH] [docs] port to mkdocs (#855) --- .github/workflows/docs.yml | 63 ++-- .gitignore | 17 +- csrc/attn/sliding_tile_attn/README.md | 2 +- docs/Makefile | 26 -- docs/README.md | 39 ++- docs/api/fastvideo.md | 248 ++++++++++++++++ docs/api/summary.md | 27 ++ docs/assets/custom.css | 41 +++ docs/{source/_static => assets}/custom.js | 0 docs/assets/images/STA_configuration.png | Bin 0 -> 100130 bytes .../_static => assets}/images/fastwan.png | Bin .../_static => assets}/images/perf.png | Bin .../_static => assets}/images/runpod_cuda.png | Bin .../_static => assets}/images/runpod_ssh.png | Bin .../images/runpod_template.png | Bin docs/assets/logos/icon_simple.svg | 6 + docs/assets/logos/logo.svg | 18 ++ .../contributing/developer_env/docker.md | 2 +- .../contributing/developer_env/index.md | 8 - .../contributing/developer_env/runpod.md | 7 +- docs/{source => }/contributing/overview.md | 1 - docs/{source => }/contributing/profiling.md | 0 docs/{source => }/design/overview.md | 15 - .../distillation/data_preprocess.md | 1 - docs/{source => }/distillation/dmd.md | 0 docs/examples/examples_index.md | 12 + docs/{source => }/generate_examples.py | 148 +++++++--- docs/getting_started/installation.md | 41 +++ .../getting_started/installation/gpu.md | 9 - .../getting_started/installation/mps.md | 9 - docs/getting_started/quick_start.md | 55 ++++ docs/getting_started/v1_api.md | 42 +++ docs/{source => }/index.md | 121 ++------ docs/{source => }/inference/add_pipeline.md | 1 - docs/{source => }/inference/cli.md | 0 docs/{source => }/inference/comfyui.md | 0 docs/{source => }/inference/configuration.md | 2 +- .../inference/inference_quick_start.md | 0 docs/{source => }/inference/optimizations.md | 19 -- docs/inference/support_matrix.md | 66 +++++ docs/make.bat | 35 --- docs/requirements-docs.txt | 15 - .../sliding_tile_attention/demo.md | 1 - .../sliding_tile_attention/installation.md | 1 - docs/source/_static/custom.css | 8 - docs/source/_templates/sections/header.html | 39 --- docs/source/api/summary.md | 19 -- docs/source/autodoc2_docstring_parser.py | 22 -- docs/source/conf.py | 275 ------------------ docs/source/getting_started/installation.md | 18 -- docs/source/getting_started/v1_api.md | 83 ------ docs/source/inference/support_matrix.md | 136 --------- docs/{source => }/training/data_preprocess.md | 1 - docs/{source => }/training/finetune.md | 2 +- .../video_sparse_attention/installation.md | 1 - mkdocs.yml | 169 +++++++++++ requirements-mkdocs.txt | 13 + 57 files changed, 936 insertions(+), 948 deletions(-) delete mode 100644 docs/Makefile create mode 100644 docs/api/fastvideo.md create mode 100644 docs/api/summary.md create mode 100644 docs/assets/custom.css rename docs/{source/_static => assets}/custom.js (100%) create mode 100644 docs/assets/images/STA_configuration.png rename docs/{source/_static => assets}/images/fastwan.png (100%) rename docs/{source/_static => assets}/images/perf.png (100%) rename docs/{source/_static => assets}/images/runpod_cuda.png (100%) rename docs/{source/_static => assets}/images/runpod_ssh.png (100%) rename docs/{source/_static => assets}/images/runpod_template.png (100%) create mode 100644 docs/assets/logos/icon_simple.svg create mode 100644 docs/assets/logos/logo.svg rename docs/{source => }/contributing/developer_env/docker.md (98%) rename docs/{source => }/contributing/developer_env/index.md (75%) rename docs/{source => }/contributing/developer_env/runpod.md (86%) rename docs/{source => }/contributing/overview.md (98%) rename docs/{source => }/contributing/profiling.md (100%) rename docs/{source => }/design/overview.md (97%) rename docs/{source => }/distillation/data_preprocess.md (98%) rename docs/{source => }/distillation/dmd.md (100%) create mode 100644 docs/examples/examples_index.md rename docs/{source => }/generate_examples.py (76%) create mode 100644 docs/getting_started/installation.md rename docs/{source => }/getting_started/installation/gpu.md (86%) rename docs/{source => }/getting_started/installation/mps.md (84%) create mode 100644 docs/getting_started/quick_start.md create mode 100644 docs/getting_started/v1_api.md rename docs/{source => }/index.md (54%) rename docs/{source => }/inference/add_pipeline.md (99%) rename docs/{source => }/inference/cli.md (100%) rename docs/{source => }/inference/comfyui.md (100%) rename docs/{source => }/inference/configuration.md (98%) rename docs/{source => }/inference/inference_quick_start.md (100%) rename docs/{source => }/inference/optimizations.md (94%) create mode 100644 docs/inference/support_matrix.md delete mode 100644 docs/make.bat delete mode 100644 docs/requirements-docs.txt rename docs/{source => }/sliding_tile_attention/demo.md (97%) rename docs/{source => }/sliding_tile_attention/installation.md (98%) delete mode 100644 docs/source/_static/custom.css delete mode 100644 docs/source/_templates/sections/header.html delete mode 100644 docs/source/api/summary.md delete mode 100644 docs/source/autodoc2_docstring_parser.py delete mode 100644 docs/source/conf.py delete mode 100644 docs/source/getting_started/installation.md delete mode 100644 docs/source/getting_started/v1_api.md delete mode 100644 docs/source/inference/support_matrix.md rename docs/{source => }/training/data_preprocess.md (98%) rename docs/{source => }/training/finetune.md (99%) rename docs/{source => }/video_sparse_attention/installation.md (98%) create mode 100644 mkdocs.yml create mode 100644 requirements-mkdocs.txt diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 1a4f4eb4a..4be7396c6 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,82 +1,55 @@ -# Sample workflow for building and deploying a Hugo site to GitHub Pages -name: Deploy FastVideo Docs to Pages +name: Deploy Documentation on: - # Runs on pushes targeting the default branch push: - branches: - - main - paths: - - "docs/**/*.md" - - "fastvideo/examples/**/*.py" + branches: [ main ] pull_request: - branches: - - main - types: [opened, ready_for_review, synchronize, reopened] - paths: - - "docs/**/*.md" - - "fastvideo/examples/**/*.py" + branches: [ main ] - # Allows you to run this workflow manually from the Actions tab - workflow_dispatch: - -# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages permissions: contents: read pages: write id-token: write -# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. -# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. concurrency: group: "pages" cancel-in-progress: false -# Default to bash -defaults: - run: - shell: bash - jobs: - pre-commit: - uses: ./.github/workflows/pre-commit.yml - - # Build job build: runs-on: ubuntu-latest - needs: pre-commit steps: - name: Checkout uses: actions/checkout@v4 - - name: Setup Pages - id: pages - uses: actions/configure-pages@v5 - - name: Set up Python + + - name: Setup Python uses: actions/setup-python@v5 with: - python-version: "3.10" + python-version: '3.12' + - name: Install dependencies run: | - cd docs - pip install -r requirements-docs.txt - - name: Build docs - run: | - cd docs - make clean - make html + python -m pip install --upgrade pip + pip install -r requirements-mkdocs.txt + + - name: Setup Pages + uses: actions/configure-pages@v4 + + - name: Build documentation + run: mkdocs build + - name: Upload artifact uses: actions/upload-pages-artifact@v3 with: - path: ./docs/build/html + path: ./site - # Deployment job deploy: environment: name: github-pages url: ${{ steps.deployment.outputs.page_url }} - if: ${{ github.event_name == 'push' }} runs-on: ubuntu-latest needs: build + if: github.ref == 'refs/heads/main' steps: - name: Deploy to GitHub Pages id: deployment diff --git a/.gitignore b/.gitignore index bb17640a5..c4023db07 100644 --- a/.gitignore +++ b/.gitignore @@ -14,6 +14,8 @@ wandb/ *.pt cache_dir/ wandb/ +venv/ +.venv/ runs/ samples/ *validation/ @@ -37,12 +39,13 @@ dist/ eggs/ .eggs/ -# Sphinx documentation -docs/_build/ -docs/source/getting_started/examples/ -docs/source/inference/examples/ -docs/source/training/examples/ -docs/source/distillation/examples/ +# MkDocs documentation +site/ +docs/getting_started/examples/ +docs/inference/examples/ +docs/training/examples/ +docs/distillation/examples/ +!requirements-mkdocs.txt # VSCode .vscode/ @@ -61,7 +64,7 @@ docs/source/distillation/examples/ !fastvideo/tests/ssim/reference_videos/**/*.mp4 # Static images -!docs/source/_static/images/**/*.png +!docs/assets/images/**/*.png !comfyui/assets/**/*.png !comfyui/assets/**/*.gif diff --git a/csrc/attn/sliding_tile_attn/README.md b/csrc/attn/sliding_tile_attn/README.md index 38c708115..4c6bfcb47 100644 --- a/csrc/attn/sliding_tile_attn/README.md +++ b/csrc/attn/sliding_tile_attn/README.md @@ -77,7 +77,7 @@ https://github.com/user-attachments/assets/f3b6dd79-7b43-4b60-a0fa-3d6495ec5747 Here is a diagram of how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