Spaces:
Runtime error
Runtime error
Logan Zoellner
commited on
Commit
·
ecbc1ab
1
Parent(s):
84519dc
why isn't latentdiffusion iface working?
Browse files
app.py
CHANGED
|
@@ -28,7 +28,7 @@ def npc_generate(name,race,characterClass):
|
|
| 28 |
"top_p": 0.9,
|
| 29 |
"temperature": 1.1,
|
| 30 |
"max_new_tokens": 50,
|
| 31 |
-
"return_full_text": False
|
| 32 |
}}
|
| 33 |
#response = requests.post(API_URL, headers=headers, json=json_)
|
| 34 |
response = requests.post(API_URL, json=json_)
|
|
@@ -55,7 +55,9 @@ def poem_to_image(poem):
|
|
| 55 |
poem = " ".join(poem.split('\n'))
|
| 56 |
poem = poem + " oil on canvas."
|
| 57 |
steps, width, height, images, diversity = '50','256','256','1',15
|
| 58 |
-
|
|
|
|
|
|
|
| 59 |
return img
|
| 60 |
|
| 61 |
demo = gr.Blocks()
|
|
|
|
| 28 |
"top_p": 0.9,
|
| 29 |
"temperature": 1.1,
|
| 30 |
"max_new_tokens": 50,
|
| 31 |
+
"return_full_text": False,
|
| 32 |
}}
|
| 33 |
#response = requests.post(API_URL, headers=headers, json=json_)
|
| 34 |
response = requests.post(API_URL, json=json_)
|
|
|
|
| 55 |
poem = " ".join(poem.split('\n'))
|
| 56 |
poem = poem + " oil on canvas."
|
| 57 |
steps, width, height, images, diversity = '50','256','256','1',15
|
| 58 |
+
iface = gr.Interface.load("spaces/multimodalart/latentdiffusion")
|
| 59 |
+
print("about to die",iface,dir(iface))
|
| 60 |
+
img=iface(poem, steps, width, height, images, diversity)[0]
|
| 61 |
return img
|
| 62 |
|
| 63 |
demo = gr.Blocks()
|