Dricz commited on
Commit
1b724ee
·
verified ·
1 Parent(s): 6ae2919

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -7
app.py CHANGED
@@ -67,14 +67,13 @@ def response2(image: gr.Image = None,image_size: gr.Slider = 640, conf_threshold
67
  conef = round(cone,3)
68
  conef = conef * 100
69
  text += (f"Detected {name[cl]} with confidence {round(conef,1)}% at ({xy[0]},{xy[1]})\n")
70
-
71
 
72
- if name[cl] == "Corn Rust":
73
- solution = "Apply fungicides with active ingredients like propiconazole or tebuconazole when symptoms appear."
74
- elif name[cl] == "Gray Leaf Spot":
75
- solution = "Use fungicides containing strobilurins (e.g., azoxystrobin) or triazoles."
76
- elif name[cl] == "Leaf Blight":
77
- solution = "Treat with fungicides such as mancozeb or chlorothalonil during the early stages."
78
 
79
  # xywh = int(results.boxes.xywh)
80
  # x = xywh[0]
 
67
  conef = round(cone,3)
68
  conef = conef * 100
69
  text += (f"Detected {name[cl]} with confidence {round(conef,1)}% at ({xy[0]},{xy[1]})\n")
 
70
 
71
+ if name[cl] == "Corn Rust":
72
+ solution = solution + "Apply fungicides with active ingredients like propiconazole or tebuconazole when symptoms appear.\n"
73
+ elif name[cl] == "Gray Leaf Spot":
74
+ solution = solution + "Use fungicides containing strobilurins (e.g., azoxystrobin) or triazoles.\n"
75
+ elif name[cl] == "Leaf Blight":
76
+ solution = solution + "Treat with fungicides such as mancozeb or chlorothalonil during the early stages.\n"
77
 
78
  # xywh = int(results.boxes.xywh)
79
  # x = xywh[0]