File size: 502 Bytes
17a6d8e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
f4e9981
17a6d8e
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/usr/bin/env python

"""gradio_interface.py: """

__author__ = "Rishabh Gupta"
__copyright__ = "Copyright 2023, Zuma"
__created_date__ = "04-08-2023"

import gradio as gr
from image_caption import get_caption


gr.Interface(fn=get_caption.get_image_caption,
             inputs=gr.Image(type="pil"),
             outputs=gr.Label(num_top_classes=3),
             examples=["image_caption/examples/bathroom.jpg", "image_caption/examples/livingRoom.jpg"]).launch()

if __name__ == '__main__':
    pass