carlosabadia
commited on
Commit
•
44f8391
1
Parent(s):
ec78ec9
Update README.md
Browse files
README.md
CHANGED
@@ -41,19 +41,18 @@ Model supported in a [Gradio](https://github.com/gradio-app/gradio) Web UI and C
|
|
41 |
|
42 |
```python
|
43 |
from diffusers import StableDiffusionPipeline, DPMSolverMultistepScheduler
|
44 |
-
import torch
|
45 |
|
46 |
-
|
|
|
|
|
|
|
|
|
47 |
|
48 |
-
|
49 |
-
|
50 |
-
pipe.scheduler = DPMSolverMultistepScheduler.from_config(pipe.scheduler.config)
|
51 |
-
pipe = pipe.to("cuda")
|
52 |
|
53 |
-
|
54 |
-
image
|
55 |
-
|
56 |
-
image.save("hasbulla.png")
|
57 |
```
|
58 |
|
59 |
![visitors](https://visitor-badge.glitch.me/badge?page_id=carlosabadia/hasbulla)
|
|
|
41 |
|
42 |
```python
|
43 |
from diffusers import StableDiffusionPipeline, DPMSolverMultistepScheduler
|
|
|
44 |
|
45 |
+
pipe = StableDiffusionPipeline.from_pretrained(
|
46 |
+
"carlosabadia/hasbulla",
|
47 |
+
scheduler = DPMSolverMultistepScheduler.from_pretrained("carlosabadia/hasbulla", subfolder="scheduler"),
|
48 |
+
torch_dtype=torch.float16,
|
49 |
+
).to("cuda")
|
50 |
|
51 |
+
guidance_scale = 7
|
52 |
+
prompt = "A portrait of hasbulla person"
|
|
|
|
|
53 |
|
54 |
+
images = pipe(prompt, num_images_per_prompt=1, num_inference_steps=50, guidance_scale=guidance_scale).images
|
55 |
+
image[0]
|
|
|
|
|
56 |
```
|
57 |
|
58 |
![visitors](https://visitor-badge.glitch.me/badge?page_id=carlosabadia/hasbulla)
|