Instructions to use YiYiXu/modular-diffdiff-0704 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use YiYiXu/modular-diffdiff-0704 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("YiYiXu/modular-diffdiff-0704", 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
Download modular_model_index.json from YiYiXu/modular-diffdiff-0704: direct link, hf CLI and curl.
- Browser
- Download file 4.16 kB
-
https://huggingface.co/YiYiXu/modular-diffdiff-0704/resolve/a2d37e0e80098e3e88e656b9e0a66f2e4259a10b/modular_model_index.json
- Command line
-
hf download hf://YiYiXu/modular-diffdiff-0704@a2d37e0e80098e3e88e656b9e0a66f2e4259a10b/modular_model_index.json
-
curl -L -o modular_model_index.json https://huggingface.co/YiYiXu/modular-diffdiff-0704/resolve/a2d37e0e80098e3e88e656b9e0a66f2e4259a10b/modular_model_index.json
4.16 kB
| { | |
| "_class_name": "StableDiffusionXLModularLoader", | |
| "_components_names": [ | |
| "text_encoder", | |
| "text_encoder_2", | |
| "tokenizer", | |
| "tokenizer_2", | |
| "guider", | |
| "image_encoder", | |
| "feature_extractor", | |
| "unet", | |
| "vae", | |
| "image_processor", | |
| "mask_processor", | |
| "scheduler", | |
| "controlnet", | |
| "control_image_processor" | |
| ], | |
| "_configs_names": [ | |
| "force_zeros_for_empty_prompt", | |
| "requires_aesthetics_score" | |
| ], | |
| "_diffusers_version": "0.34.0.dev0", | |
| "control_image_processor": [ | |
| "diffusers", | |
| "VaeImageProcessor", | |
| { | |
| "repo": null, | |
| "revision": null, | |
| "subfolder": null, | |
| "type_hint": [ | |
| "diffusers", | |
| "VaeImageProcessor" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "controlnet": [ | |
| null, | |
| null, | |
| { | |
| "repo": "diffusers/controlnet-canny-sdxl-1.0", | |
| "revision": null, | |
| "subfolder": null, | |
| "type_hint": [ | |
| "diffusers", | |
| "ControlNetModel" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "feature_extractor": [ | |
| "transformers", | |
| "CLIPImageProcessor", | |
| { | |
| "repo": null, | |
| "revision": null, | |
| "subfolder": null, | |
| "type_hint": [ | |
| "transformers", | |
| "CLIPImageProcessor" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "force_zeros_for_empty_prompt": true, | |
| "guider": [ | |
| "diffusers", | |
| "ClassifierFreeGuidance", | |
| { | |
| "repo": null, | |
| "revision": null, | |
| "subfolder": null, | |
| "type_hint": [ | |
| "diffusers", | |
| "ClassifierFreeGuidance" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "image_encoder": [ | |
| null, | |
| null, | |
| { | |
| "repo": "h94/IP-Adapter", | |
| "revision": null, | |
| "subfolder": "sdxl_models/image_encoder", | |
| "type_hint": [ | |
| "transformers", | |
| "CLIPVisionModelWithProjection" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "image_processor": [ | |
| "diffusers", | |
| "VaeImageProcessor", | |
| { | |
| "repo": null, | |
| "revision": null, | |
| "subfolder": null, | |
| "type_hint": [ | |
| "diffusers", | |
| "VaeImageProcessor" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "mask_processor": [ | |
| "diffusers", | |
| "VaeImageProcessor", | |
| { | |
| "repo": null, | |
| "revision": null, | |
| "subfolder": null, | |
| "type_hint": [ | |
| "diffusers", | |
| "VaeImageProcessor" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "requires_aesthetics_score": false, | |
| "scheduler": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "scheduler", | |
| "type_hint": [ | |
| "diffusers", | |
| "EulerDiscreteScheduler" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "text_encoder": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "text_encoder", | |
| "type_hint": [ | |
| "transformers", | |
| "CLIPTextModel" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "text_encoder_2": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "text_encoder_2", | |
| "type_hint": [ | |
| "transformers", | |
| "CLIPTextModelWithProjection" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "tokenizer": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "tokenizer", | |
| "type_hint": [ | |
| "transformers", | |
| "CLIPTokenizer" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "tokenizer_2": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "tokenizer_2", | |
| "type_hint": [ | |
| "transformers", | |
| "CLIPTokenizer" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "unet": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "unet", | |
| "type_hint": [ | |
| "diffusers", | |
| "UNet2DConditionModel" | |
| ], | |
| "variant": null | |
| } | |
| ], | |
| "vae": [ | |
| null, | |
| null, | |
| { | |
| "repo": "SG161222/RealVisXL_V4.0", | |
| "revision": null, | |
| "subfolder": "vae", | |
| "type_hint": [ | |
| "diffusers", | |
| "AutoencoderKL" | |
| ], | |
| "variant": null | |
| } | |
| ] | |
| } | |