takamarou commited on
Commit
95619c1
·
1 Parent(s): eca8cbc

sticker game

Browse files
Files changed (1) hide show
  1. modules/app.py +18 -2
modules/app.py CHANGED
@@ -35,9 +35,10 @@ def generate(prompt, negative_prompt, num_inference_steps, height, width, guidan
35
  guidance_scale=guidance_scale
36
  ).images
37
 
38
- io = gr.Interface(
39
  fn=generate,
40
  inputs=[
 
41
  gr.Textbox(label="Prompt", lines=3),
42
  gr.Textbox(label="Negative Prompt", lines=2),
43
  gr.Slider(label="Inference Steps", value=20, minimum=1, maximum=30, step=1),
@@ -48,4 +49,19 @@ io = gr.Interface(
48
  outputs=gr.Gallery(),
49
  )
50
 
51
- app = gr.mount_gradio_app(app, io, path="/gradio")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
  guidance_scale=guidance_scale
36
  ).images
37
 
38
+ play = gr.Interface(
39
  fn=generate,
40
  inputs=[
41
+ gr.Label(value="Image Generation Playground")
42
  gr.Textbox(label="Prompt", lines=3),
43
  gr.Textbox(label="Negative Prompt", lines=2),
44
  gr.Slider(label="Inference Steps", value=20, minimum=1, maximum=30, step=1),
 
49
  outputs=gr.Gallery(),
50
  )
51
 
52
+ stickers = gr.Interface(
53
+ fn=generate,
54
+ inputs=[
55
+ gr.Label(value="Sticker Optimization Console")
56
+ gr.Textbox(label="Prompt", lines=3),
57
+ gr.Textbox(label="Negative Prompt", lines=2),
58
+ gr.Slider(label="Inference Steps", value=20, minimum=1, maximum=30, step=1),
59
+ gr.Number(label="Height"),
60
+ gr.Number(label="Width"),
61
+ gr.Slider(label="Guidance Scale", value=7, minimum=1, maximum=15, step=1)
62
+ ],
63
+ outputs=gr.Gallery(),
64
+ )
65
+
66
+ app = gr.mount_gradio_app(app, play, path="/gradio")
67
+ app = gr.mount_gradio_app(app, stickers, path="/stickers")