Update app.py
Browse files
app.py
CHANGED
|
@@ -100,29 +100,13 @@ with gr.Blocks() as demo:
|
|
| 100 |
btn4 = gr.Button(value="btn4")
|
| 101 |
|
| 102 |
def iimg(text):
|
| 103 |
-
|
| 104 |
-
#img1.update(proc1("girl"))
|
| 105 |
-
#german.update("soijfoijf")
|
| 106 |
-
|
| 107 |
-
#btn2.click(proc1,inputs="girl "+randStr(),outputs=img1)
|
| 108 |
-
img01=proc1("girl "+randStr())
|
| 109 |
-
print("\n\nvvv2 "+text+randStr()+"\n\n")
|
| 110 |
-
|
| 111 |
-
img02=proc2("girl "+randStr())
|
| 112 |
-
#btn3.click(proc2,inputs="girl "+randStr(),outputs=img2)
|
| 113 |
-
print("\n\nvvv3 "+text+randStr()+"\n\n")
|
| 114 |
-
|
| 115 |
-
img03=proc3("girl "+randStr())
|
| 116 |
-
#btn4.click(proc3,inputs="girl "+randStr(),outputs=img3)
|
| 117 |
-
print("\n\nvvv4 "+text+randStr()+"\n\n")
|
| 118 |
-
return {img1:img1.update(img01),img2:img2.update(img02),img3:img3.update(img03),german:"aaaaaddddd"}#pipe(text)[0]["translation_text"]
|
| 119 |
-
|
| 120 |
#btn2.click(bbb22,inputs=english,outputs=german)
|
| 121 |
-
btn01.click(iimg, inputs=english, outputs=
|
| 122 |
-
ppStr=("girl "+randStr()+" "+english)
|
| 123 |
-
btn2.click(proc1,inputs=
|
| 124 |
-
btn3.click(proc2,inputs=
|
| 125 |
-
btn4.click(proc3,inputs=
|
| 126 |
examples = gr.Examples(examples=["I went to the supermarket yesterday.", "Helen is a good swimmer."],
|
| 127 |
inputs=[english])
|
| 128 |
|
|
|
|
| 100 |
btn4 = gr.Button(value="btn4")
|
| 101 |
|
| 102 |
def iimg(text):
|
| 103 |
+
return ("girl "+randStr()+" "+text)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 104 |
#btn2.click(bbb22,inputs=english,outputs=german)
|
| 105 |
+
btn01.click(iimg, inputs=english, outputs=english)
|
| 106 |
+
#ppStr=("girl "+randStr()+" "+english)
|
| 107 |
+
btn2.click(proc1,inputs=english,outputs=img1)
|
| 108 |
+
btn3.click(proc2,inputs=english,outputs=img2)
|
| 109 |
+
btn4.click(proc3,inputs=english,outputs=img3)
|
| 110 |
examples = gr.Examples(examples=["I went to the supermarket yesterday.", "Helen is a good swimmer."],
|
| 111 |
inputs=[english])
|
| 112 |
|