Spaces:
Sleeping
Sleeping
import gradio as gr | |
from fastai.vision.all import * | |
learn=load_learner("resnet_finetuned.pkl") | |
def classify_images(im): | |
pred,idx,probs=learn.predict(im) | |
s='Your submitted case has Prostate cancer of IUPC Grade '+pred | |
return s | |
img=gr.Image(type="pil") | |
label=gr.Label() | |
examples=["0.jpeg","2.jpeg","4.jpeg"] | |
intf=gr.Interface(title="PCa Detection ProtoType",description="This is Protorype for our model prediction",fn=classify_images,inputs=img,outputs=label,examples=examples) | |
intf.launch(inline=False,share=True) |