ipd commited on
Commit
39fff43
1 Parent(s): 0eb2a2b

updated app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -40,7 +40,7 @@ def predict(Image):
40
 
41
  with torch.no_grad():
42
  grade = torch.softmax(model(img.float()), dim=1)[0]
43
- category = ["None", "Mild", "Moderate", "Severe", "Proliferative"]
44
  output_dict = {}
45
  for cat, value in zip(category, grade):
46
  output_dict[cat] = value.item()
@@ -50,7 +50,7 @@ def predict(Image):
50
 
51
 
52
  image = gr.Image(type="pil")#shape=(224, 224), image_mode="RGB")
53
- label = gr.Label(label="Grade")
54
 
55
  demo = gr.Interface(
56
  fn=predict,
 
40
 
41
  with torch.no_grad():
42
  grade = torch.softmax(model(img.float()), dim=1)[0]
43
+ category = ["Normal", "Mild", "Moderate", "Severe", "Proliferative"]
44
  output_dict = {}
45
  for cat, value in zip(category, grade):
46
  output_dict[cat] = value.item()
 
50
 
51
 
52
  image = gr.Image(type="pil")#shape=(224, 224), image_mode="RGB")
53
+ label = gr.Label(label="Level")
54
 
55
  demo = gr.Interface(
56
  fn=predict,