Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,4 +1,14 @@
|
|
| 1 |
import gradio as gr
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2 |
|
| 3 |
def process(name):
|
| 4 |
return "hello " + name
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
+
import torch
|
| 3 |
+
from torch import autocast
|
| 4 |
+
from diffusers import StableDiffusionPipeline
|
| 5 |
+
|
| 6 |
+
print("hello sylvain")
|
| 7 |
+
|
| 8 |
+
YOUR_TOKEN="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"
|
| 9 |
+
|
| 10 |
+
pipe = StableDiffusionPipeline.from_pretrained("CompVis/stable-diffusion-v1-4", use_auth_token=YOUR_TOKEN)
|
| 11 |
+
pipe.to("cuda")
|
| 12 |
|
| 13 |
def process(name):
|
| 14 |
return "hello " + name
|