Update app.py
Browse files
app.py
CHANGED
@@ -13,19 +13,10 @@ def ac():
|
|
13 |
fac = f"{fac} "
|
14 |
return model(put),fac
|
15 |
elif h != o:
|
16 |
-
print ("Enter Password")
|
17 |
return(None,None)
|
18 |
def cl_fac():
|
19 |
return ""
|
20 |
-
def check_p(h):
|
21 |
-
if h==o:
|
22 |
-
return gr.update(visible=False)
|
23 |
-
elif h!=o:
|
24 |
-
return None
|
25 |
with gr.Blocks() as b:
|
26 |
-
with gr.Row() as r_p:
|
27 |
-
h=gr.Textbox()
|
28 |
-
pb=gr.Button()
|
29 |
with gr.Row():
|
30 |
put = gr.Textbox()
|
31 |
btn1 = gr.Button()
|
@@ -35,15 +26,13 @@ def ac():
|
|
35 |
with gr.Row():
|
36 |
out3 = gr.Image()
|
37 |
out4 = gr.Image()
|
38 |
-
|
39 |
-
|
40 |
fac_b = gr.Textbox(value="",visible=False)
|
41 |
btn1.click(cl_fac,None,fac_b)
|
42 |
btn1.click(im_fn,[put,fac_b,h],[out1,fac_b])
|
43 |
out1.change(im_fn,[put,fac_b,h],[out2,fac_b])
|
44 |
out2.change(im_fn,[put,fac_b,h],[out3,fac_b])
|
45 |
out3.change(im_fn,[put,fac_b,h],[out4,fac_b])
|
46 |
-
|
47 |
-
|
48 |
b.queue(concurrency_count=100).launch(show_api=False)
|
49 |
ac()
|
|
|
13 |
fac = f"{fac} "
|
14 |
return model(put),fac
|
15 |
elif h != o:
|
|
|
16 |
return(None,None)
|
17 |
def cl_fac():
|
18 |
return ""
|
|
|
|
|
|
|
|
|
|
|
19 |
with gr.Blocks() as b:
|
|
|
|
|
|
|
20 |
with gr.Row():
|
21 |
put = gr.Textbox()
|
22 |
btn1 = gr.Button()
|
|
|
26 |
with gr.Row():
|
27 |
out3 = gr.Image()
|
28 |
out4 = gr.Image()
|
29 |
+
with gr.Row(visible=False):
|
30 |
+
h=gr.Textbox()
|
31 |
fac_b = gr.Textbox(value="",visible=False)
|
32 |
btn1.click(cl_fac,None,fac_b)
|
33 |
btn1.click(im_fn,[put,fac_b,h],[out1,fac_b])
|
34 |
out1.change(im_fn,[put,fac_b,h],[out2,fac_b])
|
35 |
out2.change(im_fn,[put,fac_b,h],[out3,fac_b])
|
36 |
out3.change(im_fn,[put,fac_b,h],[out4,fac_b])
|
|
|
|
|
37 |
b.queue(concurrency_count=100).launch(show_api=False)
|
38 |
ac()
|