# Computer Vision and Machine Learning-Based Predictive Analysis for Urban Agricultural Systems
## 5 Results Evaluation and Discussion  
The evaluation of the regression models was based on different metrics, such as MAPE, MAE, MSE, RMSE, and R\({}^{2}\), that are commonly used for regression model evaluation [29; 30]. The results (Table 2) showed that the most accurate model based on MAPE was model #3, which forecasted soil water content sensor measurements. Model #1, which forecasted light sensor measurements, appears to have significant forecast errors, with an MAE of 332.38 and an RMSE of 781.05 for the given scale, and an MAPE exceeding 100%, indicating poor forecasting accuracy. Additionally, it was explored how this model results could be improved by incorporating memory-based time series model LSTM along with CNN model making a hybrid CNN-LSTM model [31]. The paper suggested that it could be possible to train a model by using multiple images as input, leading to the sensor measurement value that needs to be forecasted. After some experimentation it was concluded that the light intensity measurement forecast result did not improve by using this type of model. That may suggest that the thermal data need some additional parameters to be able to forecast light intensity measurements. For example, parameters like distance to windows and number of windows, in a room where plants are grown, would be just some of those that could potentially increase the forecasted measurement accuracy [32]. Another study suggests that regarding lighting estimations, a detailed representation of the physical and optical characteristics of a surface needs to be considered as a measurement forecasting model inputs [33]. Model #2, which forecasted air humidity, showed comparatively higher performance with an MAPE of 11.22%, MAE of 4.35, and RMSE of 7.09, suggesting high accuracy in its forecasts. This result matches with the other studies and correlations in this study where air humidity has an inverse correlation with air temperature. This suggests that air humidity sensor measurements can be forecasted with the given accuracy. Model #3, which forecasts soil water content, has a similar result as model #2 performance with an MAPE of 10.35%, which is slightly lower. Also, an R\({}^{2}\) value of 0.633 for model #3 suggests that this model is a potentially better fit for the data it was trained on resulting in the highest accuracy of all models. Although the MAPEs for model #2 and model #3 are similar, there are differences in MAE and RMSE values, which are comparatively higher for model #3. The differences are due to the different scales that are used for each sensor. This study's primary contribution lies in its approach to forecasting various environmental parameters crucial for urban agriculture, specifically light sensor measurements, air humidity, and soil water content, using deep learning models that can be also deployed on resource-constrained IoT devices which are commonly used throughout agriculture. The model #1 challenges in accurately forecasting light sensor measurements underline the complexity of capturing light intensity dynamics using only thermal data imagery. This insight is an addition to the field, as it directs future research towards considering additional parameters like spatial factors, reflections, or others for light forecasting. A \begin{table}
\begin{tabular}{c c c c} \hline \hline  & **Model \#1** & **Model \#2** & **Model \#3** \\  & **Scale:** & **Scale:** & **Scale:** \\  & **Min Value: 0** & **Min Value: 0\%** & **Min Value: 0** \\  & **Max Value: 65,535** & **Max Value: 100\%** & **Max Value: 4095** \\ \hline
**MAE** & 332.38 & 4.35 & 40.37 \\
**MAPE** & 100\% & 11.22\% & 10.35\% \\
**RMSE** & 781.05 & 7.09 & 68.71 \\
**R\({}^{2}\)** & 0.719 & 0.497 & 0.633 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Average results for each model in sensor measurement forecasting. comparative analysis of these models, particularly in terms of MAE and RMSE, provides critical insights into the varying challenges and considerations when modeling different environmental parameters.