Views
No views yet
nvidia/Cosmos3-Nano that
runs on Apple Silicon. The custom Cosmos3 omni-MoT diffusion transformer was ported to MLX from
scratch (no mlx-vlm support exists) and every block validated against torch. This is the quality
tier: near-lossless, and it fixes the hand/anatomy wobble seen in the 4-bit build.Derivative ofnvidia/Cosmos3-Nano. © NVIDIA. Distributed under OpenMDW-1.1 (license + NVIDIA copyright/origin notices retained). Not affiliated with, nor endorsed by, NVIDIA.
samples/barista.png,
samples/anime.png here vs the 4-bit build) — use this build when quality matters; use the
4-bit build (~11 GB) for the smallest footprint.1import torch
2from huggingface_hub import snapshot_download
3from mlx_pipeline import MLXCosmos3Transformer # included in this repo
4from diffusers import Cosmos3OmniPipeline, AutoencoderKLWan, UniPCMultistepScheduler
5from diffusers.models.autoencoders.autoencoder_cosmos3_audio import Cosmos3AVAEAudioTokenizer
6from transformers import AutoTokenizer
7
8repo = snapshot_download("Reza2kn/Cosmos3-Nano-MLX-8bit")
9vae = AutoencoderKLWan.from_pretrained(repo, subfolder="vae", torch_dtype=torch.float32).eval()
10sched = UniPCMultistepScheduler.from_pretrained(repo, subfolder="scheduler")
11tok = AutoTokenizer.from_pretrained(repo, subfolder="text_tokenizer")
12st = Cosmos3AVAEAudioTokenizer.from_pretrained(repo, subfolder="sound_tokenizer", torch_dtype=torch.float32).eval()
13pipe = Cosmos3OmniPipeline(transformer=MLXCosmos3Transformer(repo + "/transformer"),
14 text_tokenizer=tok, vae=vae, scheduler=sched, sound_tokenizer=st, enable_safety_checker=False)
15img = pipe("A red panda astronaut floating in a nebula", num_frames=1, height=384, width=384).video[0][0]
16img.save("out.png")mlx, diffusers (git main/≥0.39), transformers, torch (VAE/scheduler only).samples/).num_frames>1).bits/group_size from transformer/mlx_quant_config.json, so the same
mlx_cosmos3.py/mlx_pipeline.py code runs both the 4-bit and 8-bit builds.