hushell commited on
Commit
ef5f3c1
1 Parent(s): f8c1035

add description

Browse files
Files changed (1) hide show
  1. app.py +9 -1
app.py CHANGED
@@ -151,6 +151,11 @@ def inference(query, labels, n_supp=10,
151
  #print(output)
152
 
153
 
 
 
 
 
 
154
  gr.Interface(fn=inference,
155
  inputs=[
156
  gr.inputs.Image(label="Image to classify", type="pil"),
@@ -166,4 +171,7 @@ gr.Interface(fn=inference,
166
  gr.outputs.Label(label="Predicted class probabilities"),
167
  gr.outputs.Image(type='plot', label="Support examples from Google image search"),
168
  ],
169
- description="PMF few-shot learning with Google image search").launch(debug=True)
 
 
 
151
  #print(output)
152
 
153
 
154
+ title = "P>M>F few-shot learning pipeline with Google Image Search (GIS)"
155
+ description = "Short description: We take a ViT-small backbone, which is pre-trained with DINO, and meta-trained on Meta-Dataset; for few-shot classification, we use a ProtoNet classifier. The demo can be viewed as zero-shot since the support set is built by searching images from Google. Note that you may need to play with GIS parameters to get good support examples. Besides, GIS is not very stable as search requests may fail for many reasons (e.g., number of requests reaches the limit of the day)."
156
+ article = "<p style='text-align: center'><a href='http://arxiv.org/abs/2204.07305' target='_blank'>Arxiv</a></p>"
157
+
158
+
159
  gr.Interface(fn=inference,
160
  inputs=[
161
  gr.inputs.Image(label="Image to classify", type="pil"),
171
  gr.outputs.Label(label="Predicted class probabilities"),
172
  gr.outputs.Image(type='plot', label="Support examples from Google image search"),
173
  ],
174
+ title=title,
175
+ description=description,
176
+ article=article,
177
+ ).launch(debug=True)