MohammedAlakhras commited on
Commit
576618b
1 Parent(s): 127b1e1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -5
app.py CHANGED
@@ -21,10 +21,10 @@ from PIL import Image
21
  import gradio as gr
22
 
23
  # %% app.ipynb 2
24
- learn = load_learner('RetinalClassification.pkl')
25
 
26
  # %% app.ipynb 3
27
- categories=('cataract','diabetic_retinopathy','glaucoma','normal')
28
 
29
  def classify_image(img):
30
  pred,indx,probs=learn.predict(img)
@@ -34,9 +34,7 @@ def classify_image(img):
34
  # %% app.ipynb 4
35
  image=gr.inputs.Image(shape=(512,512))
36
  label=gr.outputs.Label()
37
- examples=['1.jpeg','10.png','11.png','12.jpeg','13.jpeg','14.jpeg','15.jpeg','16.jpeg','17.jpeg',
38
- '18.jpeg','19.jpeg','2.jpeg','20.jpeg','21.jpg','22.jpg','23.jpg','3.jpeg','4.jpeg','5.jpeg',
39
- '6.png','7.png','8.png','9.png']
40
 
41
 
42
  interface=gr.Interface(fn=classify_image, inputs=image ,outputs=label)
 
21
  import gradio as gr
22
 
23
  # %% app.ipynb 2
24
+ learn = load_learner('DentalModel.pkl')
25
 
26
  # %% app.ipynb 3
27
+ categories=('Back bridge', 'Complete prosthesis missing all teeth', 'Extraction of root remnants or a tilted wisdom tooth', 'Normal', 'Partial prosthesis (removable) missing 3 or more teeth located next to each other', 'Reprocessing', 'Rotten pulp (periapical lesion) is black around the apex and the decay extends to the nerve', 'The caries restoration did not reach the nerve of the tooth', 'The pulp is not rotten, there is no black around the apex, only the decay has reached the nerve')
28
 
29
  def classify_image(img):
30
  pred,indx,probs=learn.predict(img)
 
34
  # %% app.ipynb 4
35
  image=gr.inputs.Image(shape=(512,512))
36
  label=gr.outputs.Label()
37
+
 
 
38
 
39
 
40
  interface=gr.Interface(fn=classify_image, inputs=image ,outputs=label)