Instructions to use johnowhitaker/rainbowdiffusion with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use johnowhitaker/rainbowdiffusion with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("johnowhitaker/rainbowdiffusion", 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
- Local Apps
- Draw Things
- DiffusionBee
Commit ·
124b91d
1
Parent(s): 917d1da
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: creativeml-openrail-m
|
| 3 |
+
tags:
|
| 4 |
+
- stable-diffusion
|
| 5 |
+
- stable-diffusion-diffusers
|
| 6 |
+
- text-to-image
|
| 7 |
+
inference: true
|
| 8 |
+
---
|
| 9 |
+
|
| 10 |
+
To use the mode for inference, just load it like a normal stable diffusion pipeline:
|
| 11 |
+
|
| 12 |
+
```python
|
| 13 |
+
from diffusers import StableDiffusionPipeline
|
| 14 |
+
|
| 15 |
+
model_path = "johnowhitaker/rainbowdiffusion"
|
| 16 |
+
pipe = StableDiffusionPipeline.from_pretrained(model_path, torch_dtype=torch.float16)
|
| 17 |
+
pipe.to("cuda")
|
| 18 |
+
|
| 19 |
+
image = pipe(prompt="A cat").images[0]
|
| 20 |
+
image
|
| 21 |
+
```
|