Instructions to use rhymes-ai/Allegro with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use rhymes-ai/Allegro with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("rhymes-ai/Allegro", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Expected speed
Hi,
What's the expected inference speed one might see on various GPUs? I ran it on 1x A100 80GB using gradio built around provided code and I have speeds of around 1 iteration per 28.5s, so around 48 minutes per single 6s video. That's without cpu offloading.
On rtx 3090 / 3090 ti me and another person saw estimation of 100 iterations taking about 120/135 minutes to complete. That's with cpu offloading.
Do those performance numbers match your experiences? Is this a bug? To be honest, since this model is fairly small, I was expecting to see inference speed of a few minutes per generation, similar to CogVideoX 2B&5B.
Yes, we have tested the model on H100. It will take around 25 minutes per video (100 steps).
We plan to release a multi-GPUs inference code with context parallel.