Spaces:
Build error
Build error
Commit
·
5c02b64
1
Parent(s):
1dd4496
Updating interface
Browse files
app.py
CHANGED
@@ -85,6 +85,14 @@ def infer(url, mp_text):
|
|
85 |
|
86 |
return [np.array(image), output]
|
87 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
88 |
inputs_interface = [
|
89 |
gr.inputs.Textbox(
|
90 |
label="Url of an image.",
|
@@ -101,6 +109,8 @@ interface = gr.Interface(
|
|
101 |
fn=infer,
|
102 |
inputs=inputs_interface,
|
103 |
outputs=outputs_interface,
|
|
|
|
|
104 |
server_name="0.0.0.0",
|
105 |
server_port=8888,
|
106 |
examples=[
|
|
|
85 |
|
86 |
return [np.array(image), output]
|
87 |
|
88 |
+
title = "What's in the picture ?"
|
89 |
+
|
90 |
+
description = """
|
91 |
+
Can't find your words to describe an image ? The pre-trained
|
92 |
+
ViLT model will help you. Give the url of an image and a caption with [MASK] tokens to be filled or play with the given examples !
|
93 |
+
"""
|
94 |
+
|
95 |
+
|
96 |
inputs_interface = [
|
97 |
gr.inputs.Textbox(
|
98 |
label="Url of an image.",
|
|
|
109 |
fn=infer,
|
110 |
inputs=inputs_interface,
|
111 |
outputs=outputs_interface,
|
112 |
+
title=title,
|
113 |
+
description=description,
|
114 |
server_name="0.0.0.0",
|
115 |
server_port=8888,
|
116 |
examples=[
|