P-ID_Detection / app.py
brian25's picture
Update app.py
b0de5d8 verified
raw
history blame
260 Bytes
import gradio as gr
from ultralytics import YOLO
model = YOLO("best.pt")
def greet(source):
result = model(source) # return a list of Results objects
return result
demo = gr.Interface(fn=greet, inputs="image", outputs="image")
demo.launch()