DeepFundus / app.py
Jfink09's picture
Create app.py
8458f6b
raw
history blame
942 Bytes
import gradio as gr
# Create title, description and article strings
title = "DeepFundus πŸ‘€"
description = "A ResNet50 feature extractor computer vision model to classify retina pathology from optical funduscopic images."
article = "Created for fun."
# Create the Gradio demo
demo = gr.Interface(fn=predict, # mapping function from input to output
inputs=gr.Image(type="pil"), # what are the inputs?
outputs=[gr.Label(num_top_classes=8, label="Predictions"), # what are the outputs?
gr.Number(label="Prediction time (s)")], # our fn has two outputs, therefore we have two outputs
examples=example_list,
title=title,
description=description,
article=article)
# Launch the demo!
demo.launch(debug=False, # print errors locally?
share=True) # generate a publically shareable URL?