greendra commited on
Commit
8f40638
·
1 Parent(s): 54a951c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -223,7 +223,7 @@ def sd(prompt, negprompt, version):
223
 
224
  if artifact.type == generation.ARTIFACT_IMAGE:
225
  img = Image.open(io.BytesIO(artifact.binary))
226
- link = imagebb(prompt, img, seed)
227
  # time.sleep(2)
228
  print(version + "," + keyid + ": " + timestamp + ": PROMPT \"" + prompt + ", Neg: " + negprompt + "\" WAS GENERATED SUCCESSFULLY AND IMAGE LINK: \n" + link[1] + "\n")
229
  return img, 'Your download URL: ' + link[0] + '<br> Seed: ' + seed
@@ -258,7 +258,7 @@ with gr.Blocks(
258
  elem_id="version",
259
  )
260
 
261
- download = gr.HTML(elem_id="download", visable=False)
262
  output = gr.Image(label="Image Generation", elem_id="output")
263
  name = gr.Textbox(label="Prompt", placeholder="Describe the image you want to generate. Longer and more detailed prompts work better.", elem_id="name")
264
  negprompt = gr.Textbox(label="Negative Prompt", placeholder="Describe the image you want to avoid. Longer and more detailed prompts work better.", elem_id="negprompt")
 
223
 
224
  if artifact.type == generation.ARTIFACT_IMAGE:
225
  img = Image.open(io.BytesIO(artifact.binary))
226
+ link = freeimagehost(prompt, img, seed)
227
  # time.sleep(2)
228
  print(version + "," + keyid + ": " + timestamp + ": PROMPT \"" + prompt + ", Neg: " + negprompt + "\" WAS GENERATED SUCCESSFULLY AND IMAGE LINK: \n" + link[1] + "\n")
229
  return img, 'Your download URL: ' + link[0] + '<br> Seed: ' + seed
 
258
  elem_id="version",
259
  )
260
 
261
+ download = gr.HTML(elem_id="download")
262
  output = gr.Image(label="Image Generation", elem_id="output")
263
  name = gr.Textbox(label="Prompt", placeholder="Describe the image you want to generate. Longer and more detailed prompts work better.", elem_id="name")
264
  negprompt = gr.Textbox(label="Negative Prompt", placeholder="Describe the image you want to avoid. Longer and more detailed prompts work better.", elem_id="negprompt")