JoPmt commited on
Commit
3c052e7
·
1 Parent(s): bfe8d26

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -52,7 +52,7 @@ models =[
52
  "digiplay/PotoPhotoRealism_v1",
53
  ]
54
 
55
- def plex(prompt,goof,str(modil)):
56
  pipe = accelerator.prepare(AutoPipelineForText2Image.from_pretrained(""+modil+"", torch_dtype=torch.float32))
57
  pipe = accelerator.prepare(pipe.to("cpu"))
58
  # prompt = "A fantasy landscape, Cinematic lighting"
@@ -65,5 +65,5 @@ def plex(prompt,goof,str(modil)):
65
  image = pipe(prompt=prompt, num_inference_steps=30).images[0]
66
  return image
67
 
68
- iface = gr.Interface(fn=plex,inputs=[gr.Textbox(label="Prompt"), gr.Dropdown(choices=models,type="text",label="Model")],outputs=gr.Image(),title="AutoPipelineForText2Image_SD_Multi",description="AutoPipelineForText2Image_SD_Multi")
69
  iface.launch()
 
52
  "digiplay/PotoPhotoRealism_v1",
53
  ]
54
 
55
+ def plex(prompt,modil):
56
  pipe = accelerator.prepare(AutoPipelineForText2Image.from_pretrained(""+modil+"", torch_dtype=torch.float32))
57
  pipe = accelerator.prepare(pipe.to("cpu"))
58
  # prompt = "A fantasy landscape, Cinematic lighting"
 
65
  image = pipe(prompt=prompt, num_inference_steps=30).images[0]
66
  return image
67
 
68
+ iface = gr.Interface(fn=plex,inputs=[gr.Textbox(label="Prompt"), gr.Dropdown(choices=models, type="value")],outputs=gr.Image(),title="AutoPipelineForText2Image_SD_Multi",description="AutoPipelineForText2Image_SD_Multi")
69
  iface.launch()