mirror of
https://github.com/gradio-app/gradio.git
synced 2024-11-21 01:01:05 +08:00
interface opts
This commit is contained in:
parent
da7056d137
commit
c0765ed927
@ -6,6 +6,12 @@ def upper(sentence, sentence2):
|
||||
|
||||
|
||||
gr.Interface(upper,
|
||||
["textbox", "textbox"],
|
||||
["textbox", "textbox"],
|
||||
[
|
||||
"textbox",
|
||||
gr.inputs.Textbox(lines=3, placeholder="hello")
|
||||
],
|
||||
[
|
||||
"textbox",
|
||||
gr.outputs.Textbox(lines=3, placeholder="hello")
|
||||
],
|
||||
live=True).launch()
|
||||
|
@ -11,4 +11,9 @@ def flip2(image):
|
||||
return np.fliplr(image), time() - start
|
||||
|
||||
|
||||
gr.Interface([flip, flip2], "imagein", ["image", "textbox"]).launch()
|
||||
gr.Interface([flip, flip2],
|
||||
"imagein",
|
||||
[
|
||||
"image",
|
||||
gr.outputs.Textbox(lines=1)
|
||||
]).launch()
|
Loading…
Reference in New Issue
Block a user