Instructions to use Wan-AI/Wan2.1-I2V-14B-480P-Diffusers with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use Wan-AI/Wan2.1-I2V-14B-480P-Diffusers 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("Wan-AI/Wan2.1-I2V-14B-480P-Diffusers", torch_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") - Notebooks
- Google Colab
- Kaggle
Update image_processor/preprocessor_config.json (#3)
Browse files- Update image_processor/preprocessor_config.json (59dc91280d8f8bb7708a546651860a3f4111c51a)
Co-authored-by: YiYi Xu <YiYiXu@users.noreply.huggingface.co>
image_processor/preprocessor_config.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
"height": 224,
|
| 4 |
"width": 224
|
| 5 |
},
|
| 6 |
-
"do_center_crop":
|
| 7 |
"do_convert_rgb": true,
|
| 8 |
"do_normalize": true,
|
| 9 |
"do_rescale": true,
|
|
@@ -23,6 +23,7 @@
|
|
| 23 |
"resample": 3,
|
| 24 |
"rescale_factor": 0.00392156862745098,
|
| 25 |
"size": {
|
| 26 |
-
"
|
|
|
|
| 27 |
}
|
| 28 |
}
|
|
|
|
| 3 |
"height": 224,
|
| 4 |
"width": 224
|
| 5 |
},
|
| 6 |
+
"do_center_crop": false,
|
| 7 |
"do_convert_rgb": true,
|
| 8 |
"do_normalize": true,
|
| 9 |
"do_rescale": true,
|
|
|
|
| 23 |
"resample": 3,
|
| 24 |
"rescale_factor": 0.00392156862745098,
|
| 25 |
"size": {
|
| 26 |
+
"height": 224,
|
| 27 |
+
"width": 224
|
| 28 |
}
|
| 29 |
}
|