Spaces:
Runtime error
Runtime error
isunnyrock
commited on
Commit
•
07b7087
1
Parent(s):
d562028
minor ui changes on solutions tab
Browse files
app.py
CHANGED
@@ -384,8 +384,8 @@ Early detection of plant diseases is paramount for farmers to protect their crop
|
|
384 |
""")
|
385 |
|
386 |
# Types of Plant Diseases Detected
|
387 |
-
with st.columns(3)[
|
388 |
-
st.image(".vscode/inputs/Plant-disease-classifier-with-ai-blog-banner.jpg", width=
|
389 |
|
390 |
st.write("With more than 50% of the population in India still relying on agriculture and with the average farm sizes and incomes being very small, we believe that cost effective solutions for early detection and treatment solutions for disease could significantly improve the quality of produce and lives of farmers. With smartphones being ubiquitous, we believe providing solutions to farmers over a smartphone is the most penetrative form.")
|
391 |
|
@@ -401,7 +401,8 @@ with tab2:
|
|
401 |
print("Image successfully uploaded!")
|
402 |
# Read the uploaded image file
|
403 |
#st.image(uploaded_file, caption='Uploaded Image', use_column_width=True,width=100)
|
404 |
-
st.
|
|
|
405 |
image = Image.open(uploaded_file)
|
406 |
|
407 |
image_for_drawing = image.copy()
|
@@ -425,7 +426,8 @@ with tab2:
|
|
425 |
# Class Detections displays
|
426 |
image_with_boxes = draw_boxes(image_for_drawing, result["detection_boxes"],detection_class_entities, detection_scores)
|
427 |
#display_image(image_with_boxes)
|
428 |
-
st.
|
|
|
429 |
|
430 |
top_3_idx = np.argsort(-detection_scores)[:3]
|
431 |
plant_detection_count = 0
|
|
|
384 |
""")
|
385 |
|
386 |
# Types of Plant Diseases Detected
|
387 |
+
with st.columns(3)[0]:
|
388 |
+
st.image(".vscode/inputs/Plant-disease-classifier-with-ai-blog-banner.jpg", width=400)
|
389 |
|
390 |
st.write("With more than 50% of the population in India still relying on agriculture and with the average farm sizes and incomes being very small, we believe that cost effective solutions for early detection and treatment solutions for disease could significantly improve the quality of produce and lives of farmers. With smartphones being ubiquitous, we believe providing solutions to farmers over a smartphone is the most penetrative form.")
|
391 |
|
|
|
401 |
print("Image successfully uploaded!")
|
402 |
# Read the uploaded image file
|
403 |
#st.image(uploaded_file, caption='Uploaded Image', use_column_width=True,width=100)
|
404 |
+
with st.columns(3)[1]:
|
405 |
+
st.image(uploaded_file, caption='Image uploaded successfully. Trying to detect objects in it...', width=300)
|
406 |
image = Image.open(uploaded_file)
|
407 |
|
408 |
image_for_drawing = image.copy()
|
|
|
426 |
# Class Detections displays
|
427 |
image_with_boxes = draw_boxes(image_for_drawing, result["detection_boxes"],detection_class_entities, detection_scores)
|
428 |
#display_image(image_with_boxes)
|
429 |
+
with st.columns(3)[1]:
|
430 |
+
st.image(image_with_boxes, caption='Detected objects boxed', width=300)
|
431 |
|
432 |
top_3_idx = np.argsort(-detection_scores)[:3]
|
433 |
plant_detection_count = 0
|