File size: 6,924 Bytes
7f2bd75 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 |
# Repo Structure
```plaintext
Open-Sora
βββ README.md
βββ assets
β βββ images -> images used for image-conditioned generation
β βββ demo -> images used for demo
β βββ texts -> prompts used for text-conditioned generation
β βββ readme -> images used in README
βββ configs -> Configs for training & inference
βββ docker -> dockerfile for Open-Sora
βββ docs
β βββ acceleration.md -> Report on acceleration & speed benchmark
β βββ commands.md -> Commands for training & inference
β βββ datasets.md -> Datasets used in this project
| βββ data_processing.md -> Data pipeline documents
| βββ installation.md -> Data pipeline documents
β βββ structure.md -> This file
β βββ config.md -> Configs for training and inference
β βββ report_01.md -> Report for Open-Sora 1.0
β βββ report_02.md -> Report for Open-Sora 1.1
β βββ report_03.md -> Report for Open-Sora 1.2
β βββ vae.md -> our VAE report
β βββ zh_CN -> Chinese version of the above
βββ eval -> Evaluation scripts
β βββ README.md -> Evaluation documentation
| βββ human_eval -> for human eval
| βββ launch.sh -> script for launching 8 cards sampling
| βββ loss -> eval loss
| βββ sample.sh -> script for quickly launching inference on predefined prompts
| βββ vae -> for vae eval
| βββ vbench -> for VBench evaluation
β βββ vbench_i2v -> for VBench i2v evaluation
βββ gradio -> Gradio demo related code
βββ notebooks -> Jupyter notebooks for generating commands to run
βββ scripts
β βββ train.py -> diffusion training script
β βββ train_vae.py -> vae training script
β βββ inference.py -> diffusion inference script
β βββ inference_vae.py -> vae inference script
β βββ misc -> misc scripts, including batch size search
βββ opensora
β βββ __init__.py
β βββ registry.py -> Registry helper
βΒ Β βββ acceleration -> Acceleration related code
βΒ Β βββ datasets -> Dataset related code
βΒ Β βββ models
βΒ Β βΒ Β βββ dit -> DiT
βΒ Β βΒ Β βββ layers -> Common layers
βΒ Β βΒ Β βββ vae -> VAE as image encoder
βΒ Β βΒ Β βββ text_encoder -> Text encoder
βΒ Β βΒ Β βΒ Β βββ classes.py -> Class id encoder (inference only)
βΒ Β βΒ Β βΒ Β βββ clip.py -> CLIP encoder
βΒ Β βΒ Β βΒ Β βββ t5.py -> T5 encoder
βΒ Β βΒ Β βββ dit
βΒ Β βΒ Β βββ latte
βΒ Β βΒ Β βββ pixart
βΒ Β βΒ Β βββ stdit -> Our STDiT related code
βΒ Β βββ schedulers -> Diffusion schedulers
βΒ Β βΒ Β βββ iddpm -> IDDPM for training and inference
βΒ Β β βββ dpms -> DPM-Solver for fast inference
β βββ utils
βββ tests -> Tests for the project
βββ tools -> Tools for data processing and more
```
## Configs
Our config files follows [MMEgine](https://github.com/open-mmlab/mmengine). MMEngine will reads the config file (a `.py` file) and parse it into a dictionary-like object.
```plaintext
Open-Sora
βββ configs -> Configs for training & inference
βββ opensora-v1-1 -> STDiT2 related configs
β βββ inference
β β βββ sample.py -> Sample videos and images
β β βββ sample-ref.py -> Sample videos with image/video condition
β βββ train
β βββ stage1.py -> Stage 1 training config
β βββ stage2.py -> Stage 2 training config
β βββ stage3.py -> Stage 3 training config
β βββ image.py -> Illustration of image training config
β βββ video.py -> Illustration of video training config
β βββ benchmark.py -> For batch size searching
βββ opensora -> STDiT related configs
β βββ inference
β β βββ 16x256x256.py -> Sample videos 16 frames 256x256
β β βββ 16x512x512.py -> Sample videos 16 frames 512x512
β β βββ 64x512x512.py -> Sample videos 64 frames 512x512
β βββ train
β βββ 16x256x256.py -> Train on videos 16 frames 256x256
β βββ 16x256x256.py -> Train on videos 16 frames 256x256
β βββ 64x512x512.py -> Train on videos 64 frames 512x512
βββ dit -> DiT related configs
Β Β βΒ Β βββ inference
Β Β βΒ Β βΒ Β βββ 1x256x256-class.py -> Sample images with ckpts from DiT
Β Β βΒ Β βΒ Β βββ 1x256x256.py -> Sample images with clip condition
Β Β βΒ Β βΒ Β βββ 16x256x256.py -> Sample videos
Β Β βΒ Β βββ train
Β Β βΒ Β Β βββ 1x256x256.py -> Train on images with clip condition
Β Β βΒ Β Β Β βββ 16x256x256.py -> Train on videos
βββ latte -> Latte related configs
βββ pixart -> PixArt related configs
```
## Tools
```plaintext
Open-Sora
βββ tools
βββ datasets -> dataset management related code
βββ scene_cut -> scene cut related code
βββ caption -> caption related code
βββ scoring -> scoring related code
β βββ aesthetic -> aesthetic scoring related code
β βββ matching -> matching scoring related code
β βββ ocr -> ocr scoring related code
β βββ optical_flow -> optical flow scoring related code
βββ frame_interpolation -> frame interpolation related code
|