Instructions to use InstantX/SD3-Controlnet-Canny with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use InstantX/SD3-Controlnet-Canny with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("InstantX/SD3-Controlnet-Canny", 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
Update config.json
#12
by YiYiXu HF Staff - opened
No description provided.
corrected class name so that it can work with automodel
# test4: load a model directly (not subfolder)
controlnet_repo = "InstantX/SD3-Controlnet-Canny"
try:
controlnet_model = AutoModel.from_pretrained(
controlnet_repo,
)
print(f"test4 passed!")
except Exception as e:
print(f"test4 failed: {e}")
wanghaofan changed pull request status to merged