Spaces:
Sleeping
Sleeping
| import gradio as gr | |
| from inference import * | |
| def inference(img): | |
| img = cv2.imread(img.name) | |
| boxes, scores, cls_ids = prediction(img) | |
| return vis(img, boxes, scores, cls_ids) | |
| examples = [['input.jpg']] | |
| gr.Interface(inference, inputs=gr.inputs.Image(type="file"), outputs=gr.outputs.Image(type="pil"), | |
| examples=examples).launch() | |