Ahsen Khaliq commited on
Commit
6923ba5
1 Parent(s): 88659fd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -1
app.py CHANGED
@@ -38,4 +38,13 @@ def inference(img):
38
  return Image.fromarray(np.uint8(out.get_image())).convert('RGB')
39
 
40
 
41
- gr.Interface(inference, inputs=gr.inputs.Image(type="file"), outputs=gr.outputs.Image(type="pil")).launch()
 
 
 
 
 
 
 
 
 
 
38
  return Image.fromarray(np.uint8(out.get_image())).convert('RGB')
39
 
40
 
41
+ title = "Detectron 2"
42
+ description = "Gradio demo for Detectron 2. To use it, simply upload your image, or click one of the examples to load them. Read more at the links below."
43
+ article = "<p style='text-align: center'><a href='https://ai.facebook.com/blog/-detectron2-a-pytorch-based-modular-object-detection-library-/'>Detectron2: A PyTorch-based modular object detection library</a> | <a href='https://github.com/facebookresearch/detectron2'>Github Repo</a></p>"
44
+
45
+ examples = [['example.png']]
46
+
47
+ gr.Interface(inference, inputs=gr.inputs.Image(type="file"), outputs=gr.outputs.Image(type="pil"),enable_queue=True, title=title,
48
+ description=description,
49
+ article=article,
50
+ examples=examples).launch()