charliebaby2023 commited on
Commit
88264b8
·
verified ·
1 Parent(s): 3394932

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -48,8 +48,8 @@ def make_me():
48
  txt_input = gr.Textbox(lines=2, value=kii)
49
  #txt_input = gr.Textbox(label='Your prompt:', lines=2, value=kii)
50
 
51
- gen_button = gr.Button('Generate images', width=150, height=30)
52
- stop_button = gr.Button('Stop', variant='secondary', interactive=False, width=150, height=30)
53
 
54
  gen_button.click(lambda s: gr.update(interactive=True), None, stop_button)
55
  gr.HTML("""
@@ -59,7 +59,7 @@ def make_me():
59
  </div>
60
  """)
61
  with gr.Row():
62
- output = [gr.Image(label=m, height=170) for m in default_models]
63
  current_models = [gr.Textbox(m, visible=False) for m in default_models]
64
  for m, o in zip(current_models, output):
65
  gen_event = gen_button.click(gen_fn, [m, txt_input], o)
@@ -85,8 +85,8 @@ js_code = """
85
 
86
 
87
  with gr.Blocks(css="""
88
- .genbut { max-width: 50px; max-height: 30px; }
89
- .stopbut { max-width: 50px; max-height: 30px; }
90
  .float.svelte-1mwvhlq { position: absolute; top: var(--block-label-margin); left: var(--block-label-margin); background: none; border: none;}
91
  """) as demo:
92
  gr.Markdown("<script>" + js_code + "</script>")
@@ -98,6 +98,6 @@ demo.launch(max_threads=100)
98
 
99
 
100
 
101
-
102
  #demo.queue(concurrency_count=200)
103
  #demo.launch()
 
48
  txt_input = gr.Textbox(lines=2, value=kii)
49
  #txt_input = gr.Textbox(label='Your prompt:', lines=2, value=kii)
50
 
51
+ gen_button = gr.Button('Generate images')
52
+ stop_button = gr.Button('Stop', variant='secondary', interactive=False)
53
 
54
  gen_button.click(lambda s: gr.update(interactive=True), None, stop_button)
55
  gr.HTML("""
 
59
  </div>
60
  """)
61
  with gr.Row():
62
+ output = [gr.Image(label=m) for m in default_models]
63
  current_models = [gr.Textbox(m, visible=False) for m in default_models]
64
  for m, o in zip(current_models, output):
65
  gen_event = gen_button.click(gen_fn, [m, txt_input], o)
 
85
 
86
 
87
  with gr.Blocks(css="""
88
+ .genbut { max-width: 50px; max-height: 30px; width:150px; height:30px}
89
+ .stopbut { max-width: 50px; max-height: 30px; width:150px; height:30px}
90
  .float.svelte-1mwvhlq { position: absolute; top: var(--block-label-margin); left: var(--block-label-margin); background: none; border: none;}
91
  """) as demo:
92
  gr.Markdown("<script>" + js_code + "</script>")
 
98
 
99
 
100
 
101
+ # output = [gr.Image(label=m, height=170) for m in default_models]
102
  #demo.queue(concurrency_count=200)
103
  #demo.launch()