mswhite commited on
Commit
baa0b60
·
1 Parent(s): 76c46d1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -4
app.py CHANGED
@@ -25,8 +25,10 @@ def nagelize(text):
25
  print(prompt)
26
  return pipe(prompt).images[0]
27
 
28
- def clear(text):
29
- return gr.Image.update()
 
 
30
 
31
  with gr.Blocks() as demo:
32
 
@@ -36,9 +38,11 @@ with gr.Blocks() as demo:
36
  output = gr.Image(label="Output").style(width=720)
37
  with gr.Row():
38
  art_to_draw = gr.Textbox(label="Art to Draw")
39
- submit_btn = gr.Button("Submit")
 
40
 
41
- submit_btn.click(fn=nagelize, inputs=[art_to_draw], outputs=[output])
 
42
 
43
  demo.launch()
44
 
 
25
  print(prompt)
26
  return pipe(prompt).images[0]
27
 
28
+ def non_nagelize(text):
29
+ prompt = "text"
30
+ print(prompt)
31
+ return pipe(prompt).images[0]
32
 
33
  with gr.Blocks() as demo:
34
 
 
38
  output = gr.Image(label="Output").style(width=720)
39
  with gr.Row():
40
  art_to_draw = gr.Textbox(label="Art to Draw")
41
+ submit_btn = gr.Button("Back to the 80s")
42
+ normal_btn = gr.Button("Not going to the 80s")
43
 
44
+ submit_btn.click(fn=nagelize, inputs=[art_to_draw], outputs=[output])
45
+ normal_btn.click(fn=nagelize, inputs=[art_to_draw], outputs=[output])
46
 
47
  demo.launch()
48