Abstract
With the worsening environment quality credited to rapid urbanization and industrialization, ensuring optimal indoor air quality is a critical challenge with far-reaching implications for public health, environmental sustainability, and overall wellbeing. Despite its importance, real-time air quality monitoring solutions (AQMS) remain underdeveloped, leaving significant gaps in the ability to analyze and predict environment quality effectively. In this paper, we have presented the development of a Machine Learning Internet of Things (ML-IoT) enabled AQMS equipped with diverse sensors capable of sensing vital environmental parameters which include carbon monoxide, carbon dioxide, particulate matter PM2.5, PM10, temperature, and humidity. We deployed the developed AQMS in an indoor environment and collected environmental data from sensors. A comprehensive preprocessing pipeline, including outlier removal using the interquartile range method and feature scaling, was applied to improve data quality. Three machine learning models including Linear Regression (LR), Random Forest (RF), and Bidirectional Long Short-Term Memory (BiLSTM) were implemented for predictive analysis. Using state-of-the-art data analytics, we have tested these ML models to uncover trends, identify correlations, and predict air quality metrics with improved accuracy. To ensure methodological rigor, 5-fold cross-validation was applied to LR and RF models, while time-series cross-validation was used for BiLSTM to preserve temporal dependencies. The results show that LR achieves high accuracy for temperature prediction with R2 of 96.45% and cross validation R2 of 95.4%, while RF provides moderate performance for CO2 prediction with R2 of 52.7% and 64.05% in cross validation. BiLSTM improves CO2 prediction with R2 of 89.9%) under standard evaluation and achieves an average R2 of 85.4% under time-series validation, demonstrating generalization. To provide real-time visualization of air quality parameters, we have designed a user-friendly dashboard, allowing stakeholders to monitor real-time conditions and derive actionable insights. The developed AQMS finds promising application in industries, houses, office and residential buildings, allowing predictive environment quality monitoring and triggering alarm in case of any anomaly.
1 Introduction
Environmental pollution remains one of the most pressing global challenges, with far-reaching consequences for public health and environmental sustainability. The World Health Organization estimates that 99% of the world’s population breathes air exceeding WHO guideline limits, contributing to approximately 7 million premature deaths annually (). Urban centers bear the brunt of this crisis, where emissions from transportation, industrial activity, and energy production concentrate in high-density areas, creating persistent pollution hotspots (). Pollutants such as particulate matter (PM), nitrogen oxides (NOx), carbon monoxide (CO), and volatile organic compounds (VOCs) have been linked to a broad range of adverse health outcomes, including respiratory illness, cardiovascular disease, and neurological effects (; ). In addition to human health, air pollutants also influence atmospheric processes, contributing to changes in local and global climate systems (). Conventional air quality monitoring systems, while scientifically robust, present significant challenges in terms of cost, coverage, and timeliness. These systems typically rely on a small number of stationary reference-grade instruments that are expensive to deploy and maintain. Moreover, data from these stations is often fails to reflect the rapid spatial and temporal variability of pollution particularly in dynamic urban environments.
To address these limitations, this paper presents a low-cost, modular, and intelligent air quality monitoring system based on Internet of Things (IoT) infrastructure. The proposed architecture integrates distributed sensing with cloud-based machine learning analytics to enable real-time monitoring, pattern recognition, and pollution forecasting. The proposed system supports both immediate threshold-based alerts and longer-term environmental insights, empowering relevant stakeholders to make timely and informed decisions. By combining affordability, flexibility, and data-driven intelligence, this paper offers a practical and scalable approach to advancing modern air quality management strategies.
The evolution of air quality monitoring systems has progressed through distinct technological generations, each overcoming limitations of its predecessors while introducing new challenges. Traditional monitoring relied on expensive, fixed stations with analytical-grade instruments that provided regulatory-quality data but suffered from poor spatial resolution and delayed reporting (). These legacy systems, while accurate, proved inadequate for capturing hyperlocal pollution variations or supporting real-time public health interventions due to their centralized architecture (). Second-generation systems emerged with the development of lower-cost electrochemical and optical sensors, enabling moderate-scale deployments and monitoring at reduced costs (). However, these often suffered from calibration drift and lacked standardized data protocols ().
The introduction of IoT technologies promised to revolutionize environmental monitoring through distributed sensor networks. Early implementations demonstrated the potential of wireless systems to improve spatial coverage at much reduced costs (; ). However, these initial solutions often created new challenges where many struggled with data reliability issues, while others produced measurements without clear pathways to public health action (; ). Subsequent improvements in sensor technology and data transmission protocols (; ; ; ) helped address some technical limitations, but a persistent gap remained between data collection and community impact (). Recent approaches have begun integrating multiple components into comprehensive and intelligent monitoring solutions. Some systems now incorporate basic alert mechanisms, while others use cloud platforms for real-time data visualization (; ; ). Moreover, the hardware and software components are frequently developed in isolation, leading to fragmented user experiences and delayed responses to anomalous events (). However, to the best of our knowledge, there is an emerging need for development of integrated systems which combine the strengths of IoT, machine learning, data analysis, power monitoring, and cloud to deliver an intelligent, connected, and user-friendly AQMS which provides an end-to-end solution to air quality monitoring.
Recent advances in ML-IoT air quality monitoring systems have demonstrated the growing maturity of this field. The authors in () conducted a systematic review of low-cost IoT-enabled indoor air quality monitoring systems, identifying cloud storage and web-based visualization as dominant architectural choices while flagging sensor calibration and energy efficiency as persistent challenges. The author in () evaluated eight machine learning algorithms for calibrating low-cost IoT sensors measuring PM2.5, CO2, temperature, and humidity, demonstrating that ML-based calibration substantially improves raw sensor accuracy in indoor environments. A smart edge computing infrastructure for air quality monitoring using LPWAN and MQTT was proposed in (), showing that LoRa remains functional up to 1.65 km under realistic deployment conditions. For pollutant prediction, the authors in () systematically reviewed supervised machine learning approaches for predicting key urban pollutants, confirming the superiority of ensemble and deep learning methods over classical regression baselines. In (), the authors have developed a real-time IoT-powered AI system for air quality monitoring in industrial environments, integrating RF and deep learning pipelines within a cloud-connected sensor network. Regarding temporal deep learning, (), showed that an SSA- Bidirectional Long Short-Term Memory (BiLSTM)-LightGBM hybrid achieves strong AQI prediction performance by combining decomposition with bidirectional recurrent modeling. A novel IoT ensemble learning approach by authors in () demonstrated that stacking RF, XGBoost, MLP, and SVR for indoor CO2 prediction from multi-sensor data outperforms any single-model baseline. In (), the authors calibrated low-cost LoRaWAN-based IoT air quality monitors using a super learner ensemble, directly validating ML-based correction of PM measurements against Federal Equivalent Method instruments. For hybrid deep learning architectures, (), provided comparative analysis of LSTM, attention-augmented LSTM, and BiLSTM for air quality time-series prediction, establishing BiLSTM as the strongest performer for capturing forward and backward temporal dependencies. The authors of () benchmarked air pollution prediction with machine learning across Indian cities, demonstrating generalizability of RF and gradient boosted models for PM2.5 and composite AQI forecasting across diverse urban environments.
Our work, presented in this paper, builds upon the existing literature, by developing a unified architecture that connects real-time sensing with actionable outcomes. The system maintains the measurement rigor of traditional approaches while incorporating the distributed benefits of IoT solutions (; ). Unlike previous implementations that focused on either data collection or analysis, our design bridges this divide through coordinated hardware and software components. This integration enables both immediate community notifications and comprehensive trend analysis, supporting responses across different timescales and stakeholder needs ().
The contribution from this work lies not merely in the integration of IoT and machine learning, but in the development of a unified, end-to-end intelligent air quality monitoring framework that bridges sensing, prediction, and actionable response. Unlike existing systems that primarily focus on either data acquisition or post hoc analysis, the proposed architecture introduces a closed-loop pipeline that combines real-time sensing, cloud-based analytics, predictive modeling, and automated alert generation. Furthermore, this study provides a comprehensive experimental evaluation using a real-world dataset collected over an extended period under varying occupancy conditions, enabling analysis of temporal dynamics in indoor air quality. The comparative assessment of multiple machine learning models highlights the effectiveness of deep learning approaches, particularly BiLSTM, in capturing time-dependent environmental variations.
In contrast to prior works that emphasize system deployment or model development in isolation, this work contributes a practically deployable and analytically validated framework that integrates prediction-driven intelligence into air quality monitoring systems. The work presented in this paper provides a comprehensive evaluation using a real-world dataset collected over an extended duration under varying occupancy and weather conditions, enabling analysis of temporal dynamics in indoor air quality over an extended period of time. A comparative assessment of different machine learning models, including BiLSTM, Random Forest (RF), and Linear Regression (LR), is also presented to highlight the effectiveness of temporal modeling for dynamic pollutants. As shown in the results, due to strong generalization of the tested ML models, this analytical framework can be extended to datasets of air quality collected from other indoor environments as well.
The structure of the paper is as follows: Section 2 depicts the details on the material and methods used in the research to achieve our objectives. In Section 3, we have discussed the development and implementation of the proposed system. In Section 4, we have presented and discussed the results obtained through the deployment of the developed system while in Section 5 we have concluded the paper.
2 Materials and methods
The developed system for real-time air quality monitoring adopts a modular IoT architecture, as illustrated in Figure 1. The system integrates sensing, communication, data processing, actuation, machine learning, and visualization to provide a comprehensive end-to-end solution for environmental data acquisition, storage, analysis, and predictive learning. At the sensing layer, the system uses a suite of five calibrated sensors to sense the presence and levels of carbon monoxide (CO), carbon dioxide (CO2), Methane (CH4), temperature, humidity and particulate matter (PM). These sensors are interfaced with an ESP32 microcontroller (), which is chosen for its built-in wireless connection capabilities, low power consumption, and compatibility with embedded applications. A battery monitoring system (BMS) integrated with the controller also ensures continuous power supply to the sensing unit, allowing it to operate reliably in indoor as well as outdoor environments or under power outage conditions.
FIGURE 1
Collected sensor data is transmitted from the ESP32 to the cloud using WiFi (; ) as a wireless communication technology. The collected data is uploaded and stored in a cloud-based database that enables centralized access to environmental readings across multiple sensor nodes. The cloud platform plays a vital role not only in data management but also in enabling remote analytics and decision-making. Moreover, the system incorporates connection with actuators, which are activated by the ESP32 when predefined pollutant thresholds are crossed, allowing for immediate, localized responses to hazardous conditions.
Indoor air quality thresholds were defined based on established international standards. Particulate matter limits (PM2.5 and PM10) were adopted from the World Health Organization guidelines (), CO2 thresholds were aligned with ASHRAE Standard 62.1 for ventilation adequacy (), and carbon monoxide exposure limits were referenced from the US EPA National Ambient Air Quality Standards (NAAQS) (). In the cloud environment, incoming data is processed for real-time monitoring and forecasting. This preprocessed data is visualized on a user-friendly interface accessible through web and mobile dashboards. These dashboards provide real-time feedback, historical trends, and actionable summaries for both technical users and general audiences.
An essential component of the system is the integration of machine learning. Trained on historical sensor data, machine learning models perform predictive analytics, detect anomalies, and forecast future pollution levels. This allows the system not only to react to current conditions but also to anticipate emerging risks. The insights generated by the machine learning layer feed directly into the dashboard, offering users advanced capabilities for understanding environmental dynamics and supporting data-driven decision-making. The overall architecture forms a closed feedback loop, where real-time data from sensors continuously informs cloud analytics and machine learning, which in turn influence both the visualization layer and the actuation responses. This coordination between hardware and software components results in a responsive, adaptive, and intelligent AQMS suitable for scalable deployment in urban and semi-urban environments. The current deployment focuses on indoor validation as a baseline scenario prior to scaling toward more complex outdoor environments.
3 ML-IoT based AQMS implementation
The implementation of the proposed environment quality monitoring system follows a structured, multi-stage workflow that transforms conceptual design into a functional prototype. Starting from the sensor calibration to machine learning deployment, each phase in the implementation pipeline plays a critical role in ensuring the system’s accuracy, responsiveness, and usability. The approach emphasizes modularity and scalability, enabling both localized environmental sensing and centralized data intelligence.
3.1 The sensor node configuration and calibration
The physical assembly of the system centers on the ESP32 microcontroller, which serves as the central processing unit for acquiring, interpreting, and transmitting environmental data. All primary sensors including MQ4 (for CH4), MQ7 (for CO), MQ135 (for CO2 and other harmful gases), DHT11 (for temperature and humidity), and PMS5003 (for PM) were interfaced with the ESP32 as illustrated in the schematic diagram in Figure 2. In addition to sensors, the system incorporates control components comprising of LED indicators and a piezoelectric buzzer to provide immediate, localized alerts when pollutant thresholds are breached. In line with standard guidelines, the threshold for CO is set at 9 PPM (), for CO2 is set at 1,000 ppm and for CH4 it is 10 ppm ().
FIGURE 2
These actuators are governed by real-time input from the sensors, enabling the ESP32 to execute autonomous responses without dependence on the cloud processing. To ensure uninterrupted operation, the ESP32 is powered by a dedicated BMS. This module not only supports continuous functionality during power fluctuations but also supplies regulated voltage to all connected sensors and actuators, enhancing system stability and autonomy in remote or mobile deployments. Overall, this integrated hardware configuration establishes a cohesive framework in which sensor data, control signals, and power distribution are centrally managed, enabling a reliable, real-time monitoring.
Sensor calibration is a critical step in the AQMS’s reliable implementation to ensure accurate and consistent air quality readings. Since raw sensor outputs are voltage-based and vary with environmental factors, calibration routines were applied to align measurements with known reference values. For MQ4 and MQ7 sensors, manual calibration was conducted to adjust sensitivity levels, while for MQ135, DHT11, and PMS5003, pre-built calibration libraries were integrated into the ESP32 firmware. These routines provided corrected outputs for gas concentrations, temperature, humidity, and particulate matter. The calibration process ensured that sensor data fed into the system’s analytics pipeline was both reliable and standardized across all deployed nodes. Figure 3 depicts step by step process undertaken to calibrate sensors. The calibration process involves establishing a correlation between gases’ concentration and the ratio of sensor surface resistance (Rs) to sensor resistance at clean air (R0) for each gas sensor. Firstly, the surface resistance (Rs) is determined using Equation 1where is the load resistance, is Supply Voltage, and is voltage across Load Resistance, which is calculated using Equation 2where, represents analog values from the sensor and is the unit conversion factor obtained by dividing the maximum voltage by the maximum bit resolution of ESP32. On the other hand, the PPM concentration is obtained using Equation 3where the ratio remains constant for clean air and is extracted from the sensor sensitivity characteristic curve provided in the sensor datasheet, is slope of the line, is the intersection point. To calculate and , we consider two points and on the characteristic curve for the respective gas and calculated using Equation 4where the intersection point is computed using Equation 5
FIGURE 3
Overall, this method allows for the conversion of sensor voltage readings into PPM concentration of a gas through a series of mathematical calculations based on sensor characteristics and calibration parameters. As a result of sensor integration and calibration, Figures 4a,b depict the final node prototype with sensors installed to ensure effective sensing of pollutants and particulates.
FIGURE 4
3.2 Cloud integration
Sensor data from each node is collected at the microcontroller and then transmitted to the cloud using a structured integration process that leverages the Message Queuing Telemetry Transport (MQTT) protocol () and ThingSpeak’s API () (). Each ESP32 node is configured to publish real-time environmental data including concentrations of carbon monoxide (CO), carbon dioxide (CO2), methane, particulate matter (PM2.5 and PM10), temperature, and humidity at fixed intervals. A dedicated ThingSpeak channels were created for the node, with individual fields mapped to specific sensor parameters. Using unique API keys associated with the channel, the ESP32 transmits data using MQTT protocol. These API calls ensure secure and synchronized communication between the sensing hardware and the cloud platform. The integration also allows for automatic error handling and channel-based data validation. This API-driven integration not only facilitates seamless cloud connectivity but also establishes a foundation for subsequent data analytics and machine learning workflows within the system.
3.3 Data collection and visualization
To evaluate system performance of this AQMS node in a controlled indoor setting, it was deployed in a laboratory for an extended time period. The lab environment, which is air-conditioned and enclosed, provided a stable baseline for sensor readings. The node remained in place for a period of 3 months. This duration also included a month-long semester break where the lab occupancy was at its lowest, with minimal human activity, followed by 2 months of regular academic activity, with higher occupancy, offering a contrasting dataset for comparative analysis. The environmental conditions of the laboratory are expected to influence sensor behavior. Once installed, the node initiated real-time data acquisition via onboard sensors. The microcontroller managed sensor communication and transmitted the collected data over a Wi-Fi connection using the MQTT protocol. The data was routed to the cloud through ThingSpeak, where it was stored in structured channels linked to MQTT topics. Each parameter was assigned to a dedicated field for organized logging and visualization. The dashboard on ThingSpeak was configured to update every 10 min, providing near real-time tracking of environmental variables.
To complement the basic visualizations provided by ThingSpeak, a more advanced and interactive dashboard was developed using Microsoft Power BI (). Data collected by the sensor nodes and stored on ThingSpeak was accessed using its RESTful API. Each ThingSpeak channel was configured with secure API keys, and a custom Python script was written to periodically fetch the data. Once retrieved, the data was preprocessed to remove inconsistencies and stored in a SQL Server database. This structured storage allowed for efficient querying, reliable archival, and seamless integration with downstream analytics tools. Power BI was then connected directly to the SQL Server database using its native data connectors. Scheduled refreshes and a live data link were configured to ensure that the dashboard remained synchronized with the most recent sensor readings. This setup established a continuous data pipeline from the deployed sensor nodes to the visualization layer, enabling users to observe, interpret, and act on environmental changes in near real time. The Real-time integration of Power BI dashboard, shown in Figure 5, presents an intuitive and interactive interface where users can filter data by specific time intervals, zoom into sensor-specific events, and compare variables across different environmental conditions.
FIGURE 5
3.4 Machine learning
The primary objective of applying machine learning to the collected indoor air quality dataset is to explore, preprocess, and model the data to understand and predict key environmental parameters. The selection of machine learning models in this study is guided by the need to capture both linear and nonlinear relationships, as well as temporal dependencies in environmental data. To comprehensively evaluate the performance of the implemented machine learning models, three standard regression metrics were employed, namely, coefficient of determination (R2), Root Mean Square Error (RMSE), and Mean Absolute Error (MAE). Each of these metrics provides complementary insights into model performance and prediction accuracy. The R2 score was selected as a primary metric to measure the proportion of variance in the target variable that is explained by the model. RMSE was incorporated to quantify the average magnitude of prediction errors while giving higher weight to larger deviations. In addition, MAE was used as a complementary metric to provide a more interpretable measure of average absolute error. Unlike RMSE, MAE treats all errors equally, making it less sensitive to outliers and more reflective of typical model performance. The combination of these metrics ensures a balanced evaluation by capturing both the explanatory capability (R2) and error characteristics (RMSE and MAE) of the models.
The process begins with an exploratory data analysis (EDA), followed by implementation of machine learning models. The models were chosen to form a deliberate progression of increasing capacity, allowing us to attribute predictive performance to specific characteristics of the data. Firstly, LR establishes whether the target can be explained by linear relationships among the predictors. Secondly, RF was selected to capture nonlinear feature interactions without distributional assumptions, while providing interpretable feature-importance estimates and robustness to scaling and residual outliers. Lastly BiLSTM models sequential dependencies using both past and future context within each window. Hyperparameters for the three models were set to widely adopted, literature-supported default configurations for each model family, chosen for stability and reproducibility (; ). The step by step process for EDA and applications of models is depicted in Figure 6. The EDA begins with data loading, inspection, and cleaning. The raw dataset exported from the ThingSpeak platform comprised 117,354 records representing the complete logging history of the sensor node, accumulated across the full deployment period including device commissioning, sensor calibration trials, and intermittent pre-study testing. For analysis purposes, the dataset was deliberately restricted to a validated continuous monitoring window of 53 days, during which the node operated under stable, calibrated conditions; records logged outside this window were excluded as they do not represent valid study-period measurements, and this temporal filtering accounts for the bulk of the overall record reduction. Subsequently, infinite values arising from sensor transmission errors were converted to NaN, and all rows containing NaN values were removed to ensure numerical integrity prior to modelling. The Interquartile Range (IQR) method was then applied to CO2, PM2.5, PM10, and Humidity data to remove physically implausible extreme values attributable to transient sensor noise. Finally, Temperature readings were constrained to an ambient-valid range of 15 °C–50 °C, as values falling outside this band are indicative of sensor malfunction rather than genuine ambient conditions. Following the application of these sequential preprocessing steps, the final retained dataset comprised 56,413 records, which formed the basis for all subsequent modelling and analysis.
FIGURE 6
Table 1 provides a summary of the dataset’s statistical properties which include total count, mean, standard deviation, minimum value, maximum value, and quartiles for each feature. The CO levels have a mean of 0.049 ppm, ranging from 0.030 ppm to 0.060 ppm. This low and consistent level of CO is expected in an indoor, air-conditioned environment with minimal sources of CO gas. The CO2 levels have a mean of 472.468 ppm with a standard deviation of 66.321 ppm, ranging from 273.090 ppm to 669.740 ppm. These levels are within a typical range for indoor environments, though the upper limit approaches levels that could cause discomfort, indicating periods of higher occupancy or insufficient ventilation. The temperature has a mean of 31.026 °C with a standard deviation of 5.473 °C, ranging from 16 °C to 44 °C. This range suggests variations due to different times of the day or changes in air conditioning settings, with the mean temperature being relatively high for an air-conditioned space. Humidity levels have a mean of 34.595% with a standard deviation of 7.677%, ranging from 22% to 51%. These levels are within a comfortable range for indoor environments, with variations likely influenced by external weather conditions or occupancy levels. PM10 levels have a mean of 65.955 μg/m3 with a standard deviation of 4.997 μg/m3, ranging from 53 μg/m3 to 78 μg/m3. These low levels indicate effective air filtration and minimal sources of particulates in the controlled indoor environment.
TABLE 1
| Statistic | CO (ppm) | CO2 (ppm) | Temperature (°C) | Humidity (%) | PM10 (µg/m3) |
|---|---|---|---|---|---|
| Count | 56,413 | 56,413 | 56,413 | 56,413 | 56,413 |
| Mean | 0.049170 | 472.467,956 | 31.026234 | 34.594,747 | 65.955,259 |
| Std dev | 0.004138 | 66.32268 | 5.472,785 | 7.677,157 | 4.997,236 |
| Min | 0.03 | 273.090 | 16.00 | 22.00 | 53.00 |
| 25% (Q1) | 0.0 | 432.660 | 27.00 | 28.00 | 63.0 |
| Median (Q2) | 0.0 | 462.160 | 32.00 | 34.559,268 | 67.00 |
| 75% (Q3) | 0.05 | 517.110 | 35.00 | 40.00 | 70.0 |
| Max | 0.06 | 669.740 | 44.00 | 51.00 | 78.0 |
AQMS dataset’s statistical properties.
A LR model was implemented as a baseline to capture linear relationships between environmental variables. The model was trained using CO, CO2, humidity, and PM10 as input features to predict temperature. A 70–30 train-test split was used for evaluation. A RF Regressor was employed to model nonlinear relationships for CO2 prediction. The model was configured with 500 decision trees and trained using CO, temperature, humidity, and PM10 as input features. A 90–10 train-test split was used. A BiLSTM network was implemented to capture temporal dependencies in CO2 concentration. The model consists of a BiLSTM layer with 128 units, followed by a dropout layer (with rate = 0.2) and a dense output layer. Input sequences of length 10 time steps were constructed using environmental features including temperature, humidity, PM10, CO, and CO2. The model was trained with a learning rate of 0.001, for 30 epochs and a batch size of 32, with a validation split of 10%. A time-based train-test split (90–10) was used to preserve temporal structure. This combination enables a comprehensive evaluation of model performance across different levels of complexity.
The correlation matrix was computed using Pearson method and reported in Figure 7, which reveals the relationships between different air quality parameters, with values ranging from −1 to 1. A value close to 1 indicates a strong positive correlation, while a value close to −1 indicates a strong negative correlation. Values near 0 suggest weak or no correlation. The results in Figure 7 show that the correlation between CO and CO2 is −0.043, indicating a weak negative relationship. This suggests that when CO levels increase, CO2 levels slightly decrease, though the relationship is not strong. The correlation between temperature and humidity is 0.98, indicating that higher temperatures may be associated with higher humidity levels, which is reasonable in an air-conditioned environment. The correlation between temperature and PM10 is 0.076, suggesting that higher temperatures may be associated with slightly higher levels of PM10, possibly due to increased activity or reduced effectiveness of air filtration at higher temperatures. Other correlations between parameters like CO2 and PM10, and CO and temperature, are very weak, indicating that these factors are relatively independent of each other in indoor environment.
FIGURE 7
To model these relationships, two supervised learning techniques, LR, and RF () were applied. A LR model was trained to predict temperature based on CO, CO2, humidity, and PM10. A RF regression model was used to predict CO2 levels, which are inherently more dynamic. Moreover, to improve predictive behavior and effectively capture temporal dependencies in the data, a BiLSTM neural network () was developed and deployed. Data preprocessing included robust scaling and the creation of time-series sequences from environmental features. The outcomes obtained through these models are presented in Section 4.
4 Results and discussion
A two-step analysis was conducted to evaluate indoor air quality variations and the effectiveness of predictive modeling within a controlled indoor environment. The first part focuses on sensor data collected during two distinct occupancy periods in a laboratory environment, one during very low occupancy during semester break and the other during higher occupancy when academic activities were in progress. The second part included the application of 3 ML models trained on the dataset obtained through the sensor data collection activity. A total of 117,354 samples of air quality parameters where collected during the experiment. This was followed by pre-processing the sensor data to rule out any outliers and anomalies.
Figure 8 presents the boxplots of the air quality parameters obtained after preprocessing of the collected dataset. The boxplots provide a statistical overview of the distribution, central tendency, and variability of the monitored environmental parameters. It can be observed that CO and temperature exhibit relatively consistent distributions with limited variability, which is expected in a controlled indoor environment. In contrast, CO2 and humidity show comparatively higher spread, indicating the influence of occupancy levels and ventilation conditions within the laboratory. CH4 readings display the presence of outliers, which are attributed to experimental fire ignited to test the working of the gas sensor. The annotated median values further highlight the central tendency of each parameter, while the whiskers illustrate the dispersion of the dataset. A comparative analysis of environmental parameters during and after the semester break (vacation) highlights the influence of laboratory occupancy on indoor air quality. During the initial phase, when the laboratory remained in low occupancy, pollutant levels including PM2.5, CO, and CO2, remained consistently low, with minimal variation in temperature and humidity due to the stable, air-conditioned environment. This is evident from Figures 9a, 10a, 11a, 12a, 13a showing PM2.5, Temperature, Humidity, CO, and CO2 readings in low occupancy scenario respectively. In contrast, the resumption of academic activities post-semester break led to noticeable increase and variation in pollutant concentrations, particularly during peak occupancy hours, as evident from Figures 9b, 10b, 11b, 12b, 13b showing PM2.5, Temperature, Humidity, CO, and CO2 readings in high occupancy scenario respectively. These changes in the behavior reflect the impact of human presence, electronic equipment usage, and ventilation dynamics. The clear contrast between low and high occupancy periods reinforces the importance of deploying real-time air quality monitoring systems in indoor settings to monitor and control ventilation and maintain safe indoor conditions.
FIGURE 8
FIGURE 9
FIGURE 10
FIGURE 11
FIGURE 12
FIGURE 13
Besides comparing air quality parameters in different occupancy conditions, three machine learning models were also implemented on the collected air quality data, to evaluate if the collected data set from the developed AQMS can accurately predict future values of the monitored parameters. To evaluate the models’ performance on the test data set, we have considered three evaluation metrics, namely, coefficient of determination (R2), Root Mean Square Error (RMSE) and Mean Absolute Error (MAE), which are computed for each ML model. RMSE and MAE complement R2 by quantifying prediction error magnitudes. The first model implemented was the LR model and it was trained to estimate temperature using CO, CO2, humidity, and PM10 as input variables. The model achieved an R2 score of 96.45%, RMSE of 1.75, and MAE of 1.37, indicating strong predictive accuracy. This result highlights the potential of simple regression models for temperature forecasting in stable indoor environments, offering valuable support for HVAC system optimization. The prediction of CO2 concentrations presented a more complex challenge. For this purpose, RF regression model was used which utilizes 500 decision trees to make predictions. Using RF regression model, an R2 of 52.7%, RMSE of 2.44, and MAE of 0.48 for CO2 prediction was obtained. Although the performance accuracy was moderate, the model effectively identified key predictors, CO, humidity, and PM10 providing meaningful insight into the factors that significantly influence indoor CO2 variability.
To further improve prediction accuracy for CO2, a BiLSTM neural network was deployed. This model architecture includes a BiLSTM layer with 128 units, enabling the network to capture dependencies in both forward and backward directions across time steps. This bidirectional capability enhances the model’s ability to learn complex temporal relationships in the data. A dropout layer with a rate of 0.2 is added to prevent overfitting by randomly deactivating a fraction of neurons during training, thereby improving generalization. A dense output layer with one unit predicts the CO2 level at the next time step based on the preceding sequences of environmental variables. The model is compiled with the mean squared error loss function and the Adam optimizer for training. The model has been trained for 30 epochs with a batch size of 32. During training, a validation split of 10% is used to monitor the model’s performance on unseen data and prevent overfitting. By leveraging the temporal structure of the data, the BiLSTM achieved an R2 score of 89.9%, RMSE of 2.68, and MAE of 0.52, significantly outperforming the RF regression model. Table 2 presents the comparative performance of LR, RF, and BiLSTM models. The results indicate that LR performs adequately for predicting relatively stable variables such as temperature but exhibits limited capability in capturing complex relationships. RF demonstrates improved performance for CO2 prediction by modeling nonlinear interactions among environmental variables. Although the BiLSTM model is designed to capture temporal dependencies, its performance in this study is comparable to RF. This suggests that the indoor air quality dataset, collected in a controlled environment, exhibits limited temporal variability, thereby reducing the advantage of deep learning-based sequential models.
TABLE 2
| Model type | Input variables | Targeted variable | R2 | RMSE | MAE |
|---|---|---|---|---|---|
| Linear regression | CO, humidity, CO2, PM10 | Temperature | 96.45% | 1.75 | 1.37 |
| Random forest regression | CO, temperature, humidity, PM10 | CO2 | 52.7% | 2.44 | 0.48 |
| BiLSTM | CO, temperature, humidity, PM10 | CO2 | 89.9% | 2.68 | 0.52 |
Summary of application of ML models on air quality parameters.
To further validate the robustness of the models, -fold cross-validation was performed for the machine learning models. In -fold cross-validation, the dataset is divided into equal subsets, and the model is trained and evaluated times, each time using a different subset as the test set and the remaining data for training. The final performance is obtained by averaging the results across all folds, providing a more reliable estimate of model generalization. A 5-fold cross-validation strategy was applied to the LR and RF model, while a time-series cross-validation approach was used for the BiLSTM model to preserve temporal dependencies in the dataset. The LR model was evaluated using 5-fold cross validation achieved an average R2 score of 95.4%, RMSE of 1.54, and MAE of 1.4. The RF model was evaluated using 5-fold cross-validation with input variables including CO, temperature, humidity, and PM10. The model achieved an average R2 score of 64.05%, RMSE of 4.47, and MAE of 0.71. The results indicate moderate predictive performance with noticeable variability across folds, suggesting sensitivity to data distribution and the presence of outliers. BiLSTM model was evaluated using 5-fold Time Series Cross-Validation (TSCV) to ensure temporal integrity and prevent data leakage. The final fold (Fold 5) yielded the strongest generalization performance, achieving an R2 of 85.44%, an RMSE of 1.3440, and a MAE of 1.02 across all folds. The R2 value indicates that the BiLSTM model successfully captured approximately 85% of the variance in CO2 concentrations, demonstrating a meaningful ability to model the underlying temporal dynamics of the air quality sensor data. Table 3 summarizes the performance of LR, RF and BiLSTM models assessed through cross validation techniques.
TABLE 3
| Model | R2 (%) | RMSE | MAE |
|---|---|---|---|
| Linear regression (5-fold) | 95.4% | 1.54 | 1.4 |
| Random forest (5-fold) | 64.05% | 4.47 | 0.71 |
| BiLSTM (time-series 5-fold CV) | 85.44% | 1.3440 | 1.02 |
Summary of application of ML models on air quality parameters.
Figure 14 depicts the feature importance of CO, temperature, humidity, and PM10 on CO2 levels. This insight is crucial for identifying key factors influencing indoor air quality and guiding strategies for optimizing these conditions during higher occupancy. As evident from Figure 14, humidity and PM10 shows higher levels of contributions in CO2 variability then CO and temperature.
FIGURE 14
The final step in analysis involves visualizing the model predictions against the true CO2 values over time steps using BiLSTM. Figures 15a,b illustrate the extent of prediction performed by the model for CO2 levels compared to the actual observations, providing insights into the model’s accuracy and its ability to capture temporal dependencies in the data. Visual comparisons between actual and predicted values confirmed the BiLSTM model’s robustness in capturing dynamic CO2 trends as evident in Figure 15b. The BiLSTM’s ability to interpret past patterns and forecast future fluctuations positions it as a promising tool for intelligent environmental control in spaces with varying occupancy and activity levels.
FIGURE 15
While several studies have explored IoT-based air quality monitoring or machine learning-based prediction independently, the developed system distinguishes itself by integrating these components into a cohesive and operational framework. The inclusion of real-time prediction and threshold-based actuation enables proactive environmental management rather than passive monitoring. While the proposed ML-IoT based AQMS has been validated through a 3-month deployment in a controlled indoor laboratory environment, the current evaluation is limited to a single setting with relatively stable environmental conditions. As such, the generalizability of the system to outdoor or highly dynamic urban environments may require further investigation. In outdoor scenarios, air quality monitoring is influenced by additional factors such as meteorological variations (wind speed, solar radiation), traffic emissions, and spatial heterogeneity, which introduce higher variability and noise in sensor readings.
Despite these challenges, the proposed system architecture is inherently modular and scalable. The use of ESP32-based nodes, cloud integration, and machine learning pipelines enables straightforward extension to distributed deployments across multiple locations. The machine learning models can be retrained or fine-tuned using location-specific data to adapt to diverse environmental conditions. Additionally, incorporating auxiliary features such as meteorological data and spatial information can further enhance model performance in outdoor environments. Therefore, while the current study focuses on indoor validation, the proposed framework provides a flexible foundation for large-scale, real-world deployment in smart city applications, subject to appropriate calibration, data enrichment, and model adaptation. Table 4 shows the costing for components of the device, which totals to an estimated cost of USD 37, including wiring, PCB and casing. This costing is considered low-cost compared to other prototype devices presented in recent literature (; ) with approximate cost of at least EUR 1500 and commercial devices available in the market (; ) with approximate cost of at least USD 150.
TABLE 4
| Component | Function | Cost |
|---|---|---|
| ESP32 controller | Acquisition + Wi-fi transmit | USD 5 |
| MQ7 sensor | Carbon monoxide (CO) | USD 2 |
| MQ135 sensor | Carbon dioxide (CO2) | USD 2 |
| PM5003 sensor | PM2.5/PM10 | USD 13 |
| MQ4 sensor | Methane (CH4) | USD 2 |
| DHT11 sensor | Temperature + humidity | USD 2 |
| Buzzer + LEDs | Threshold alerting | USD 2 |
| Alkaline cells + holder | Power supply | USD 3 |
| PCB/wiring/enclosure | Assembly | USD 6 |
| Total cost (approx.) | USD 37 | |
Costing information on sensor node components for prototype.
Even though the dataset used in this study is relatively large, it is collected from a single indoor laboratory environment with controlled conditions, which may limit variability in environmental parameters. This can potentially lead to overfitting, where machine learning models capture environment-specific patterns rather than generalizable relationships. To mitigate this, preprocessing and modeling strategies were employed, including outlier removal, robust scaling, and the use of validation splits during training. In particular, the BiLSTM model incorporates dropout regularization and validation-based training to reduce overfitting. However, it is acknowledged that model performance may degrade when applied to unseen environments with different pollutant sources, ventilation characteristics, or environmental dynamics. To improve generalization, future work will focus on training models using multi-location datasets and incorporating additional contextual features such as occupancy levels and meteorological conditions. Transfer learning or domain adaptation techniques may also be employed to adapt pretrained models to new environments with minimal retraining.
5 Conclusion
In this paper, we have presented an innovative ML-IoT based AQMS, designed and developed to successfully address critical limitations in existing monitoring approaches. Through the integration of calibrated sensors with controller, real-time cloud integration and visualization, hardware alerts, and data analytics, we have developed a comprehensive solution that bridges the gap between pollution detection and community response. Our research makes three primary contributions to the field of environmental monitoring. First, a modular and cost-effective IoT-based architecture was designed and implemented using calibrated sensors, demonstrating reliable acquisition of indoor air quality parameters. Second, a robust data processing pipeline was developed, incorporating preprocessing techniques such as outlier removal using the interquartile range method and feature scaling to enhance data quality and consistency. Third, a comprehensive machine learning framework was established using LR, RF, and BiLSTM models to capture linear, nonlinear, and temporal relationships in environmental data. To improve methodological transparency and ensure reliable performance evaluation, cross-validation strategies were incorporated. A 5-fold cross-validation approach applied to the LR and RF model yielded an average R2 of 95.4% and 64.05% respectively, while time-series cross-validation applied to the BiLSTM model achieved an average R2 of 85.44%. These results provide a more realistic estimate of model generalization and highlight the importance of rigorous validation in environmental prediction systems. The results demonstrate that LR performs effectively for stable parameters such as temperature, while RF and BiLSTM provide improved modeling of CO2 variability. However, the moderate performance under cross-validation indicates that the controlled indoor dataset exhibits limited variability, thereby constraining the advantages of complex deep learning models. Moreover, the user-centric design of the proposed system successfully addresses the accessibility gap in environmental monitoring, enabling participation from both technical and non-technical stakeholders. The results were obtained from a single-node prototype operating in a controlled indoor laboratory over a multi-week period. The architecture is designed to be scalable to multiple nodes, and future work will focus on multi-node outdoor deployment, co-location against reference-grade instruments to quantify accuracy and sensor drift. The technical framework provides a scalable model for urban air quality monitoring, particularly in resource-constrained settings where traditional systems are impractical. Furthermore, the integration of ML with IoT based sensor network establishes a foundation for predictive pollution modeling that could transform how cities anticipate and manage air quality crises. Other alternative models which were not included in this work include XGBoost, which follows tree ensemble in the same family as RF model. RF was retained as the representative tree ensemble for its built-in feature-importance interpretation and fewer tuning-sensitive hyper parameters. Besides XGBoost, SARIMA, which is a classical linear univariate time-series model that assumes stationarity and a fixed seasonal period. Because, the target parameter is driven by multiple nonlinearly coupled variables, a learned multivariate model was better suited than a univariate seasonal one. Future enhancements may include real-time occupancy detection, adaptive retraining, or automated ventilation controls, advancing the vision of responsive, health-aware indoor infrastructure.
Statements
Data availability statement
The raw data supporting the conclusions of this article will be made available by the authors, without undue reservation.
Author contributions
Tanzila: Software, Visualization, Writing – original draft. SA: Investigation, Resources, Writing – original draft. MIA: Conceptualization, Supervision, Writing – review and editing. IA: Resources, Writing – review and editing. MSA: Formal Analysis, Writing – review and editing. SK: Data curation, Investigation, Writing – review and editing. MH: Formal Analysis, Validation, Writing – review and editing. MA: Data curation, Methodology, Visualization, Writing – review and editing. IK: Funding acquisition, Project administration, Writing – review and editing.
Funding
The author(s) declared that financial support was received for this work and/or its publication. This result was supported by the “Regional Innovation System and Education (RISE)” through the Ulsan RISE Center, funded by the Ministry of Education (MOE) and the Ulsan Metropolitan City, Republic of Korea (2026-RISE-07–001).
Conflict of interest
The author(s) declared that this work was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.
Generative AI statement
The author(s) declared that generative AI was not used in the creation of this manuscript.
Any alternative text (alt text) provided alongside figures in this article has been generated by Frontiers with the support of artificial intelligence and reasonable efforts have been made to ensure accuracy, including review by the authors wherever possible. If you identify any issues, please contact us.
Publisher’s note
All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article, or claim that may be made by its manufacturer, is not guaranteed or endorsed by the publisher.
References
1
AbdullahM.NoorG.AliS.AhmedI.AslamM. I. (2025). Development of cellular IoT-Based, portable outdoor air quality monitoring system for pollution mapping. Eng. Proc.118, 30. 10.3390/ECSA-12-26529
2
AbubekerK. M.PrajithaC.RineshS.ArunM.Senthil KumarA. P. (2025). Internet of things and LoRaWAN-assisted real-time indoor air quality monitoring and automation system for enhancing passenger safety. Int. J. Low-Carbon Technol.20, 1427–1439. 10.1093/ijlct/ctaf083
3
AgencyU. S. E. P. (2023). National ambient air quality standards (NAAQS) for carbon monoxide. Available online at: https://www.epa.gov/criteria-air-pollutants/naaqs-table (Accessed June 11th, 2024).
4
AleixandreM.GerbolesM. (2012). Review of small commercial sensors for indicative monitoring of ambient gas. Chem. Eng. Trans.30, 169–174. 10.3303/CET1230029
5
Amazon (2026). Switch. CO2 Detect. Air Qual. Monit. Indoor, CO2 Monit. CO2/TEMP/Humidity, Portable Carbon Dioxide Detect. Home/Car/Office/Greenhouse. Available online at: https://a.co/d/0ecrDDWu (Accessed June 8, 2026).
6
ApteJ. S.MessierK. P.GaniS.BrauerM.KirchstetterT. W.LundenM. M.et al (2017). High-resolution air pollution mapping with google street view cars: exploiting big data. Environ. Sci. and Technol.51, 6999–7008. 10.1021/acs.est.7b00891
7
ASHRAE (2025). Ventilation and acceptable indoor air quality, ANSI/ASHRAE standard 62.1-2025. Available online at: https://www.ashrae.org/technical-resources/bookstore/standards-62-1-62-2 (Accessed June 8, 2026).
8
AslamM. I.AliS.ShahH. K.SiddiqS.ShoukatE.KhanY. A. (2024). “Development and implementation of AI-Enabled, remote vitals monitoring system using LoRaWAN,” in 2024 4th International Conference on Innovations in Computer Science (ICONICS). IEEE, 1–5.
9
BalagopalG.WijeratneL.WaczakJ.HathurusingheP.IqbalM.KivD.et al (2025). Calibration of low-cost LoRaWAN-Based IoT air quality monitors using the super learner ensemble: a case study for accurate particulate matter measurement. Sensors25, 1614. 10.3390/s25051614
10
BhardwajD.RagiriP. R. (2024). “A deep learning approach to enhance air quality prediction: comparative analysis of LSTM, LSTM with attention mechanism and BiLSTM,” in 2024 IEEE Region 10 Symposium (TENSYMP), 2024. IEEE, 1–8.
11
BiM. P. (2025). Microsoft power BI. Available online at: https://app.powerbi.com/(Accessed May 2, 2026).
12
BlockM. L.Calderón-GarcidueñasL. (2009). Air pollution: mechanisms of neuroinflammation and CNS disease. Trends Neurosciences32, 506–516. 10.1016/j.tins.2009.05.009
13
Camarillo-EscobedoR.FloresJ. L.Marin-MontoyaP.García-ToralesG.Camarillo-EscobedoJ. M. (2022). Smart multi-sensor system for remote air quality monitoring using unmanned aerial vehicle and LoRaWAN. Sensors22, 1706. 10.3390/s22051706
14
Cardenas-JuarezM.Aguilar-GonzalezR.SimonJ.RizzardiA.DiazG.Ruiz-CorreaS. (2024). “Implementation of a low-cost IoT indoor air quality monitor in dynamic public environments,” in 2024 IEEE Virtual Conference on Communications (VCC), 2024. IEEE, 1–7.
15
CastellN.DaugeF. R.SchneiderP.VogtM.LernerU.FishbainB.et al (2017). Can commercial low-cost sensor platforms contribute to air quality monitoring and exposure estimates?Environ. International99, 293–302. 10.1016/j.envint.2016.12.007
16
ChanY.-W.KristianiE.FathoniH.ChenC.-Y.YangC.-T. (2024). A smart edge computing infrastructure for air quality monitoring using LPWAN and MQTT technologies. J. Supercomput.80, 9961–9985. 10.1007/s11227-023-05837-5
17
ChandrasekaranG.KumarN. S.VG.PriyadarshiN.KhanB. (2025). IoT enabled smart solar water heater system using real time ThingSpeak IoT platform. IET Renew. Power Gener.19, e12760. 10.1049/rpg2.12760
18
ESP32 (2025). Available online at: https://www.espressif.com/en/products/socs/esp32 (Accessed May 2nd, 2025).
19
EssamlaliI.NhailaH.EL KhailiM. (2024). Supervised machine learning approaches for predicting key pollutants and for the sustainable enhancement of urban air quality: a systematic review. Sustainability16, 976. 10.3390/su16030976
20
FerrariP.SisinniE.BellagenteP.CarvalhoD. F.DepariA.FlamminiA.et al (2022). On the use of LoRaWAN and cloud platforms for diversification of Mobility-as-a-Service infrastructure in smart city scenarios. IEEE Trans. Instrum. Meas.71, 1–9. 10.1109/tim.2022.3144736
21
FioreA. M.NaikV.LeibenspergerE. M. (2015). Air quality and climate connections. J. Air and Waste Manag. Assoc.65, 645–685. 10.1080/10962247.2015.1040526
22
IQAIR (2026). AirVisual pro indoor monitor. Available online at: https://www.iqair.com/products/air-quality-monitors/airvisual-pro-indoor-monitor?Title=Default+Title (Accessed June 8th, 2026).
23
Kareem Abed AlzabaliS.BastamM.AtaieE. (2024). A novel IoT-integrated ensemble learning approach for indoor air quality enhancement. J. Supercomput.80, 25315–25344. 10.1007/s11227-024-06416-y
24
KortoçiP.MotlaghN. H.ZaidanM. A.FungP. L.VarjonenS.Rebeiro-HargraveA.et al (2022). Air pollution exposure monitoring using portable low-cost air quality sensors. Smart Health23, 100241. 10.1016/j.smhl.2021.100241
25
KumarK.PandeB. P. (2023). Air pollution prediction with machine learning: a case study of Indian cities. Int. J. Environ. Sci. Technol.20, 5333–5348. 10.1007/s13762-022-04241-5
26
KumarP.MorawskaL.MartaniC.BiskosG.NeophytouM.DI SabatinoS.et al (2015). The rise of low-cost sensing for managing air pollution in cities. Environ. International75, 199–205. 10.1016/j.envint.2014.11.019
27
KumarA.KumariM.GuptaH. (2020). “Design and analysis of iot based air quality monitoring system,” in 2020 International Conference on Power Electronics and IoT Applications in Renewable Energy and Its Control (PARC). IEEE, 242–245.
28
MalikP. K.SharmaR.SinghR.GehlotA.SatapathyS. C.AlnumayW. S.et al (2021). Industrial internet of things and its applications in industry 4.0: state of the art. Comput. Commun.166, 125–139. 10.1016/j.comcom.2020.11.016
29
MeadM.PopoolaO.StewartG.LandshoffP.CallejaM.HayesM.et al (2013). The use of electrochemical sensors for monitoring urban air quality in low-cost, high-density networks. Atmos. Environ.70, 186–203. 10.1016/j.atmosenv.2012.11.060
30
Medina-PérezA.Sánchez-RodríguezD.Alonso-GonzálezI. (2021). An internet of thing architecture based on message queuing telemetry transport protocol and node-red: a case study for monitoring radon gas. Smart Cities4, 803–818. 10.3390/smartcities4020041
31
MessanS.ShahudA.AnisA.KalamR.AliS.AslamM. I. (2022). Air-MIT: air quality monitoring using internet of things. Eng. Proc.20, 45. 10.3390/engproc2022020045
32
MorawskaL.ThaiP. K.LiuX.Asumadu-SakyiA.AyokoG.BartonovaA.et al (2018). Applications of low-cost sensing technologies for air quality monitoring and exposure assessment: how far have they gone?Environ. International116, 286–299. 10.1016/j.envint.2018.04.018
33
OrganizationW. H. (2021a). WHO Ambient (Outdoor) Air Pollution.
34
OrganizationW. H. (2021b). WHO Global Air Quality Guidelines: Particulate Matter (PM2.5 and PM10), ozone, nitOogen dNoxide, sDlfur dioSide anD carbon monCxide.
35
PatchmuthuR. K.WanA. T.SuhailiW. S. (2022). Exploring data security and privacy issues in internet of things based on five-layer architecture. Int. J. Commun. Netw. Inf. Secur. (IJCNIS)12, 108–121. 10.17762/ijcnis.v12i1.4345
36
PeixeJ.MarquesG. (2024). Low-cost IoT-enabled indoor air quality monitoring systems: a systematic review. J. Ambient. Intell. Smart Environ.16, 167–180. 10.3233/ais-220577
37
Pope IIIC. A.DockeryD. W. (2006). Health effects of fine particulate air pollution: lines that connect. J. Air and Waste Management Association56, 709–742. 10.1080/10473289.2006.10464485
38
RaiA. C.KumarP.PillaF.SkouloudisA. N.DI SabatinoS.RattiC.et al (2017). End-user perspective of low-cost sensors for outdoor air pollution monitoring. Sci. Total Environ.607, 691–705. 10.1016/j.scitotenv.2017.06.266
39
RamadanM. N.AliM. A.KhooS. Y.AlkhedherM.AlherbawiM. (2024). Real-time IoT-powered AI system for monitoring and forecasting of air pollution in industrial environment. Ecotoxicol. Environmental Safety283, 116856. 10.1016/j.ecoenv.2024.116856
40
SamadA.KieserJ.ChourdakisI.VogtU. (2024). Developing a cloud-based air quality monitoring platform using low-cost sensors. Sensors24, 945. 10.3390/s24030945
41
ShabbirM.SaeedT.SaleemA.BhaveP.BerginM.KhokharM. F. (2025). A paradigm shift: low-Cost sensors for effective air quality monitoring and management in developing countries. Environ. Int.200, 109521. 10.1016/j.envint.2025.109521
42
SnyderE. G.WatkinsT. H.SolomonP. A.ThomaE. D.WilliamsR. W.HaglerG. S.et al (2013). The changing paradigm of air pollution monitoring. Environ. Science and Technology47, 11369–11377. 10.1021/es4022602
43
TanzilaA. L. I. S.AslamM. I.AhmedI.AhmedA. (2025a). Prototyping LoRaWAN-Based Mobile air quality monitoring system for public health and safety. Eng. Proc.118, 20. 10.3390/ECSA-12-26510
44
TanzilaS. A.AslamM. I.AhmedI. (2025b). “Development of a LoRaWAN-Based Mobile air quality monitoring system for public health and safety,” in 10th International Electrical Engineering Conference. Pakistan. Available online at: https://ieec.neduet.edu.pk/ieec_drupal/sites/default/files/IEEC_2025/Proceeding/Papers%20(IEEC%202025).pdf (Accessed July 8, 2026).
45
TaştanM. (2025). Machine learning–based calibration and performance evaluation of low-cost internet of things air quality sensors. Sensors25, 3183. 10.3390/s25103183
46
ThingspeakM. (2025). Mathworks ThingSpeak. Available online at: https://thingspeak.mathworks.com/(Accessed May 2nd, 2025).
47
ZhangX.JiangX.LiY. (2023). Prediction of air quality index based on the SSA-BiLSTM-LightGBM model. Sci. Rep.13, 5550. 10.1038/s41598-023-32775-2
48
ZhangZ.ZhangS.ChenC.YuanJ. (2024). A systematic survey of air quality prediction based on deep learning. Alexandria Eng. J.93, 128–141. 10.1016/j.aej.2024.03.031
Summary
Keywords
air quality, Bi-LSTM, environment quality, internet of things, machine learning, random forest
Citation
Tanzila, Ali S, Aslam MI, Ahmed I, Ayub MS, Kulsoom SK, Hussain M, Asif M and Koo I (2026) Design, development, and evaluation of ML-IoT enabled environment quality monitoring system. Front. Environ. Sci. 14:1822757. doi: 10.3389/fenvs.2026.1822757
Received
04 March 2026
Revised
18 June 2026
Accepted
22 June 2026
Published
15 July 2026
Volume
14 - 2026
Edited by
Yuanzheng Cui, Chinese Academy of Sciences (CAS), China
Reviewed by
Rupa Kesavan, Sri Venkateswara College of Engineering, India
Claudia Banciu, Lucian Blaga University of Sibiu, Romania
Agustina Rachmawardani, Sekolah Tinggi Meteorologi Klimatologi dan Geofisika, Indonesia
Updates
Copyright
© 2026 Tanzila, Ali, Aslam, Ahmed, Ayub, Kulsoom, Hussain, Asif and Koo.
This is an open-access article distributed under the terms of the Creative Commons Attribution License (CC BY). The use, distribution or reproduction in other forums is permitted, provided the original author(s) and the copyright owner(s) are credited and that the original publication in this journal is cited, in accordance with accepted academic practice. No use, distribution or reproduction is permitted which does not comply with these terms.
*Correspondence: Muhammad Imran Aslam, iaslam@neduet.edu.pk; Insoo Koo, iskoo@ulsan.ac.kr
Disclaimer
All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article or claim that may be made by its manufacturer is not guaranteed or endorsed by the publisher.