Abstract
Rooftop gardening is increasingly popular in urban areas with limited agricultural space, but many gardeners abandon it due to the rapid spread of plant diseases and a lack of timely diagnosis. This research aims to develop an automated, accurate leaf-disease detection system to assist rooftop gardeners and small-scale growers in maintaining healthy plants. The paper hypothesizes a machine learning-based diagnostic system that diagnoses diseases using leaf images, based on an image segmentation algorithm and a robust classification model. Image segmentation serves as a crucial preprocessing step to isolate relevant areas affected by disease, thereby enhancing classification accuracy. The system has been trained and tested with a large dataset comprising leaf images of five commonly cultivated species: guava, jamun, lemon, mango, and pomegranate. Model effectiveness was evaluated using performance metrics such as Accuracy, Sensitivity, Precision, and F1-Score. The experimental results demonstrate high and consistent performance across all plant categories. The model achieved an ideal Accuracy of 1.00, along with corresponding Sensitivity, Precision, and F1-score. Notably, lemon and mango disease classifications achieved high accuracy, with scores of 0.995 and 0.991, respectively, and F1-Scores exceeding 0.88. The proposed approach has significant implications for real-time plant disease monitoring, facilitating precise agriculture practices and promoting the sustainability of rooftop gardening by enabling early disease detection and timely intervention.

