File size: 584 Bytes
e7e7fcf
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Python Text2Image Inference

```python
from diffusers import DiffusionPipeline, DPMSolverMultistepScheduler
import torch

repo_id = "hearmeneigh/sd21-e621-rising-v1"
pipe = DiffusionPipeline.from_pretrained(repo_id, torch_dtype=torch.float16, revision="fp16")

pipe.scheduler = DPMSolverMultistepScheduler.from_config(pipe.scheduler.config)
pipe = pipe.to("cuda")

prompt = "anthro species:equine solo male biped standing rating:questionable evil_grin seductive looking_at_viewer"
image = pipe(prompt, guidance_scale=9, num_inference_steps=25).images[0]
image.save("horse.png")
```