Abrar20 commited on
Commit
537af0d
·
verified ·
1 Parent(s): 62cf647

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -2
app.py CHANGED
@@ -37,8 +37,6 @@ def classify_image_vit(image):
37
 
38
  # Predicted label
39
  predicted_label = vit_model.config.id2label.get(predicted_class_idx, "Unknown")
40
- # Example: If your id2label from HF is something like "corn diseased" or "rice healthy",
41
- # match it to the dictionary key for treatments (above). For demonstration:
42
  treatment_text = vit_label_treatment.get(predicted_label, "No specific treatment available.")
43
  return predicted_label, treatment_text
44
 
 
37
 
38
  # Predicted label
39
  predicted_label = vit_model.config.id2label.get(predicted_class_idx, "Unknown")
 
 
40
  treatment_text = vit_label_treatment.get(predicted_label, "No specific treatment available.")
41
  return predicted_label, treatment_text
42