Addai commited on
Commit
08be317
·
1 Parent(s): ae9c6b8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -1
app.py CHANGED
@@ -13,8 +13,14 @@ def predict(img):
13
  # Provide explanation based on the prediction
14
  if pred == "cancer_positive":
15
  explanation = "The model predicts that the image shows signs of cancer."
16
- else:
17
  explanation = "The model predicts that the image does not show signs of cancer."
 
 
 
 
 
 
18
 
19
  return prediction, explanation
20
 
 
13
  # Provide explanation based on the prediction
14
  if pred == "cancer_positive":
15
  explanation = "The model predicts that the image shows signs of cancer."
16
+ elif pred == "cancer_negative":
17
  explanation = "The model predicts that the image does not show signs of cancer."
18
+ elif pred == "implant_cancer_positive":
19
+ explanation = "The model predicts that the image shows signs of implant-related cancer."
20
+ elif pred == "implant_cancer_negative":
21
+ explanation = "The model predicts that the image does not show signs of implant-related cancer."
22
+ else:
23
+ explanation = "Unknown prediction."
24
 
25
  return prediction, explanation
26