Instructions to use sand-ai/MAGI-1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use sand-ai/MAGI-1 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image, export_to_video # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("sand-ai/MAGI-1", dtype=torch.bfloat16, device_map="cuda") pipe.to("cuda") prompt = "A man with short gray hair plays a red electric guitar." image = load_image( "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/guitar-man.png" ) output = pipe(image=image, prompt=prompt).frames[0] export_to_video(output, "output.mp4") - MAGI-1
How to use sand-ai/MAGI-1 with MAGI-1:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Download IMG_7487.jpeg from sand-ai/MAGI-1: direct link, hf CLI and curl.
- Browser
- Download file 224 kB
-
https://huggingface.co/sand-ai/MAGI-1/resolve/refs%2Fpr%2F18/IMG_7487.jpeg
- Command line
-
hf download hf://sand-ai/MAGI-1@refs/pr/18/IMG_7487.jpeg
-
curl -L -o IMG_7487.jpeg https://huggingface.co/sand-ai/MAGI-1/resolve/refs%2Fpr%2F18/IMG_7487.jpeg
224 kB

- Xet hash:
- e7aeef721196e3634a9760fd6d7ca0ba4d39dfb30dd455621eefb229c9c3cbca
- Size of remote file:
- 224 kB
- SHA256:
- abb02c6d75b8407fd37f7d7e424a2f8277bb9422876c8ce23e5bedc657b70d10
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.