Skip to content

Add Cosmos3 FP8 quantization cookbook and serving examples - #298

Open
wkutak wants to merge 6 commits into
NVIDIA:mainfrom
wkutak:cosmos3-fp8-quantization-recipe
Open

Add Cosmos3 FP8 quantization cookbook and serving examples#298
wkutak wants to merge 6 commits into
NVIDIA:mainfrom
wkutak:cosmos3-fp8-quantization-recipe

Conversation

@wkutak

@wkutak wkutak commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator

New cookbooks/cosmos3/quantization/ ships a self-contained ModelOpt static-scale FP8 recipe:

  • src/: the Cosmos3 DiT model + full recipe (load, calibrate on real denoising, export a drop-in diffusers checkpoint).
  • notebooks/: quantize Nano/Super, Super Text-to-Image, and Super Image-to-Video (base + 4-step distilled).
  • Reproduces the shipped FP8 checkpoints bit-for-bit.

Also add a "Quantized Checkpoints" section to the vLLM-Omni generator notebooks (audiovisual, action, transfer) and the vLLM reasoner notebook: serving the FP8 build is just --revision fp8.

New cookbooks/cosmos3/quantization/ ships a self-contained ModelOpt
static-scale FP8 recipe:
- src/: the Cosmos3 DiT model + full recipe (load, calibrate on real
  denoising, export a drop-in diffusers checkpoint).
- notebooks/: quantize Nano/Super, Super Text-to-Image, and Super
  Image-to-Video (base + 4-step distilled).
- Reproduces the shipped FP8 checkpoints bit-for-bit.

Also add a "Quantized Checkpoints" section to the vLLM-Omni generator
notebooks (audiovisual, action, transfer) and the vLLM reasoner
notebook: serving the FP8 build is just --revision fp8.

Signed-off-by: Wojciech Kutak <wkutak@nvidia.com>
@wkutak
wkutak marked this pull request as ready for review July 30, 2026 13:01
@wkutak wkutak changed the title [DRAFT] Add Cosmos3 FP8 quantization cookbook and serving examples Add Cosmos3 FP8 quantization cookbook and serving examples Jul 30, 2026
@qmiao-hub
qmiao-hub requested a review from rickzw July 30, 2026 18:06
@qmiao-hub

Copy link
Copy Markdown
Collaborator

@wkutak , who is the tester validate the inference function and user guide in this PR? The person should be reviewer of this PR as well, approve once tested working with log test result in google doc.

@qmiao-hub
qmiao-hub self-requested a review July 30, 2026 21:15
Signed-off-by: Wojciech Kutak <wkutak@nvidia.com>
@qmiao-hub

Copy link
Copy Markdown
Collaborator

@KrzysztofTomala - please review and approve this PR once you completed testing.

@KrzysztofTomala

Copy link
Copy Markdown
Collaborator

vLLM cookbook

The model download and server startup works fine. I had to remove

 do_sample_frames": True

from the video example as the requests were failing, but the issue is happening also on the non-FP8 model.

@KrzysztofTomala

Copy link
Copy Markdown
Collaborator

vLLM-Omni cookbooks
The model download and server startup works fine
Audiovisual - everything works
Forward dynamics - AV works, Robotics - fail, but it is not FP8 released
Inverse dynamics - works
Transfer - I had to disable guardrails, as they block some examples. Without guardrails everything works

@KrzysztofTomala

Copy link
Copy Markdown
Collaborator

Quantization cookbooks

Everything works, there are a couple of warning, but nothing crucial.
I have been wondering why do we need 3 notebooks, not just one? Also maybe we should publish the notebooks without outputs, as they make scrolling through them inconvenient.

@KrzysztofTomala KrzysztofTomala left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall everything works as expected, all of the serious problems are not FP8 related

Comment thread cookbooks/cosmos3/quantization/notebooks/quantize_nano_super.ipynb Outdated
Comment thread cookbooks/cosmos3/quantization/README.md Outdated
Comment thread cookbooks/cosmos3/generator/audiovisual/run_with_vllm_omni.ipynb Outdated
wkutak added 2 commits August 4, 2026 06:34
…d99f1254459ef3a4f1bd4263'

Signed-off-by: Wojciech Kutak <wkutak@nvidia.com>
… README, small fixes

Signed-off-by: Wojciech Kutak <wkutak@nvidia.com>
@wkutak
wkutak requested a review from KrzysztofTomala August 4, 2026 13:46
@MaciejBalaNV

Copy link
Copy Markdown
Collaborator

The transfer example issue @KrzysztofTomala mentioned will be fixed here: #299
The forward dynamics issue is fixed here on the dataset sample level, I'll take another look if vllm-omni notebooks needs some fixes as well: #302

@MaciejBalaNV

Copy link
Copy Markdown
Collaborator

@wkutak Can you please fix the merge conflict?

@wkutak

wkutak commented Aug 7, 2026

Copy link
Copy Markdown
Collaborator Author

Merge conflicts fixed, @rickzw please review the PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants