rishirajbal commited on
Commit
eb80dfb
·
verified ·
1 Parent(s): 270b631

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -46,7 +46,7 @@ def classify_image_and_stats(image_input):
46
  total_area = IMG_HEIGHT * IMG_WIDTH
47
  tumor_ratio = tumor_area / total_area
48
 
49
- tumor_label = "Tumor Detected" if tumor_ratio > 0.0025 else "No Tumor Detected"
50
 
51
  overlay = np.array(img)
52
  red_mask = np.zeros_like(overlay)
@@ -125,7 +125,7 @@ inputs = [
125
 
126
  outputs = [
127
  gr.Image(type="numpy", label="Overlay: Brain MRI + Tumor Mask"),
128
- gr.Textbox(label="Doctor's Explanation (Typing...)")
129
  ]
130
 
131
  if __name__ == "__main__":
 
46
  total_area = IMG_HEIGHT * IMG_WIDTH
47
  tumor_ratio = tumor_area / total_area
48
 
49
+ tumor_label = "Tumor Detected" if tumor_ratio > 0.0035 else "No Tumor Detected"
50
 
51
  overlay = np.array(img)
52
  red_mask = np.zeros_like(overlay)
 
125
 
126
  outputs = [
127
  gr.Image(type="numpy", label="Overlay: Brain MRI + Tumor Mask"),
128
+ gr.Textbox(label="Doctor's Explanation")
129
  ]
130
 
131
  if __name__ == "__main__":