Erick Garcia Espinosa commited on
Commit
010feb3
·
1 Parent(s): 1853757

Add application file and dependencies

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -6,7 +6,7 @@ from PIL import Image
6
  from timm import create_model
7
  import matplotlib.pyplot as plt
8
 
9
- class_to_idx = {'Monkeypox': 0, 'Chickenpox': 1, 'Measles': 2, 'Melanoma': 3, 'Herpes': 4}
10
  idx_to_class = {v: k for k, v in class_to_idx.items()}
11
 
12
  # Data transformation
@@ -64,7 +64,7 @@ iface = gr.Interface(
64
  inputs=gr.Image(type="filepath", label="Upload an image"),
65
  outputs=[gr.Label(label="Prediction"), gr.Image(label="Prediction Probabilities")],
66
  title="Skin Lesion Image Classification",
67
- description="Upload an image of a skin lesion to get a prediction with confidence percentages. Example images: [Link to Example 1](#), [Link to Example 2](#)",
68
  theme="huggingface",
69
  live=True
70
  )
 
6
  from timm import create_model
7
  import matplotlib.pyplot as plt
8
 
9
+ class_to_idx = {'Monkeypox': 0, 'Measles': 1, 'Chickenpox': 2, 'Herpes': 3, 'Melanoma': 4}
10
  idx_to_class = {v: k for k, v in class_to_idx.items()}
11
 
12
  # Data transformation
 
64
  inputs=gr.Image(type="filepath", label="Upload an image"),
65
  outputs=[gr.Label(label="Prediction"), gr.Image(label="Prediction Probabilities")],
66
  title="Skin Lesion Image Classification",
67
+ description="Upload an image of a skin lesion to get a prediction . Check out the dataset and paper at: [Link to Example 1](#), [Link to Example 2](#)",
68
  theme="huggingface",
69
  live=True
70
  )