Spaces:
Runtime error
Runtime error
Axel-Student
commited on
Commit
·
7857c96
1
Parent(s):
789ecb4
generate images + add secret
Browse files
app.py
CHANGED
@@ -19,15 +19,7 @@ client = InferenceClient(
|
|
19 |
)
|
20 |
|
21 |
def generate_image(prompt):
|
22 |
-
image =
|
23 |
-
prompt,
|
24 |
-
height=1024,
|
25 |
-
width=1024,
|
26 |
-
guidance_scale=3.5,
|
27 |
-
num_inference_steps=50,
|
28 |
-
max_sequence_length=512,
|
29 |
-
generator=torch.Generator("cpu").manual_seed(0)
|
30 |
-
).images[0]
|
31 |
return image
|
32 |
|
33 |
gradio_app = gr.Interface(
|
|
|
19 |
)
|
20 |
|
21 |
def generate_image(prompt):
|
22 |
+
image = client.text_to_image(prompt)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
return image
|
24 |
|
25 |
gradio_app = gr.Interface(
|