<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Time Series Prediction Of AQI using Facebook Prophet and YOLOV5</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Omer Qureshi</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Muhammad Osaid</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Muhammad Atif Tahir</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Muhammad Nouman Durrani</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>National University of Computer and Emerging Sciences</institution>
          ,
          <addr-line>Karachi</addr-line>
          ,
          <country country="PK">Pakistan</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>This paper describes the method proposed by team VSL_FAST_NUCES for the task of predicting: Air Quality Index using Sensors and Cameras Data at MediaEval, 2022. This task aims to predict AQI levels of air by using sensors data and images from diferent cameras. Our proposed approach is that we collect air pollutants data from diferent sensors and then used Facebook Prophet to predict pollutants value and AQI. For the images data we used YOLOv5 to extract objects in images and then applied FB Prophet prediction on them to predict AQI level from images. The Best RMSE is on Sensor 7 which is 5.77% With economic development, growth in population, and other factors, air pollution has become a threat to the lives of individuals. The MediaEval 2022 Air Quality Index challenge [1] consisted of two tasks: Task 1 and Task 2. In task 1, it is required to predict the air quality pollutants such as PM2.5, PM10, CO, NO2 &amp; O3 by using the environmental data. On the other hand, Task 2 required predicting the air quality by using the trafic data. This paper explores the new technique to predict AQI values of sensors data and cameras images using FBProphet [2] and YOLOv5 algorithm.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
    </sec>
    <sec id="sec-2">
      <title>2. Related Work</title>
      <p>
        In the research [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ], the authors estimated PM2.5 at the current time and predicted it over the
short to medium term. The proposed approach utilizes the relationship between urban nature,
urban trafic, and air pollution to devise an estimation model. The authors use fuzzy logic to
create temporal records of the environment, transportation and urban nature.
      </p>
      <p>
        There has been a number of methodologies to predict the air quality index. In [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] the authors
propose to combine the visual features and AQI lifelogs. The features of the visual data were
extracted through CNN and the AQI was calculated via the standard methodology. The purpose
of the model was to establish a relationship between the visual features and AQI through a
multi-layer perceptron(MLP) model.
      </p>
      <p>
        In [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] the authors estimate AQI through regression by considering variables such as timestamp,
location and weather. The algorithms include linear regression, support vector machines etc.
The model evaluation was done through accuracy and the F1 score. It can be seen that the
XGBoost algorithms gave the best results.
      </p>
    </sec>
    <sec id="sec-3">
      <title>3. Approach</title>
      <p>3.1. Task 1
Two diferent approaches were adopted for Task 1 and Task 2 respectively and they are as
follows:
The first approach was a time series problem where the requirement was to predict the value
of the respective pollutants over a period of time. For this approach, the Facebook Prophet
(FbProphet) algorithm was used to predict the values of all the pollutants on an hourly basis.
3.2. Task 2
In task 2, the pictures from camera 2 were used to extract the objects through the YOLOv5
algorithm. The main objects identified were cars, people, bicycles, trucks &amp; motorcycles. The
frequency of these objects was determined and the respective AQI at the given moment of time
was considered to be the closest hour. After the propagation of the value of objects and AQI, a
simple regression was run to determine the relationship between the objects and AQI.</p>
      <p>There was a positive relationship between AQI PM 2.5, AQI PM 10, AQI CO and the presence
of a person and car in the image.</p>
      <p>The expected values of the objects over a period of time were determined through the
FbProphet algorithm. These forecasted values of the objects were subsequently used with the
values of the linear regression to give us an expected AQI value.</p>
    </sec>
    <sec id="sec-4">
      <title>4. Results and Analysis</title>
      <p>The challenge in predicting the pollutants was the unavailability of regular time series data.
There were numerous instances where the data was missing for a number of days and
interpolation was the only solution. However, even with interpolation, the results could vary significantly
over the months as the magnitude of the values varied significantly from month to month.</p>
      <p>For Task1, sensors 4,7 and 10 were considered. These sensors were selected for prediction as
they were one of the "live" sensors.</p>
      <p>For Task 2, we used YOLOv5 on the pictures captured from camera2 and used the values
from sensor 2. The reason for selecting camera 2 and sensor 2 was the fact that they had
similar longitude and latitude which means that they were in close proximity to each other. The
appended consists of the results for Task1 and Task 2.</p>
      <sec id="sec-4-1">
        <title>4.1. Task 1 Results</title>
        <p>Prophet Algorithm.</p>
        <p>In this task, we extract AQI values for each pollutant and simple values for pollutants using FB</p>
        <p>As we can see for sensor 4, date 11/25/2022 time 5 PM - 6 PM, PM2.5 48.73 value is unhealthy
and their AQI is also lies in unhealthy range which is 132.76 . For CO, date 11/25/2022 time 5
PM - 6 PM, value is 3.36 which is in good range and their predicted AQI is also good 38.36. For
sensor 7, date 11/23/2022 time 11 PM - 12 PM, PM10 value is is 5.95 which is good and their
predicted AQI is 12.87 which is also good. For sensor 10, date 11/25/2022 time 5 PM - 6 PM, CO
value is 39.89 which is hazardous and their predicted AQI is 382.88 which is also in hazardous
range.
Values for respective pollutants for sensor 4, 7 &amp; 10.</p>
        <p>Sensor #</p>
        <p>Date
Sensor 4
11/23/2022
11/18/2022
11/25/2022
11/18/2022
11/25/2022
11/18/2022
11/25/2022
Sensor 7</p>
        <p>11/23/2022
Sensor 10
11/23/2022</p>
      </sec>
      <sec id="sec-4-2">
        <title>4.2. Task 2 Results</title>
        <p>The results indicate that 5 PM - 6 PM is the time slot which has the most amount of activity for
all the days ; which leads to an increase in all pollutants besides O3. It is also interesting to note
that the 8 AM to 9 AM slot appears to have more pollutants than 11 AM - 12 PM; this may be
attributed to some morning activities by the population.</p>
      </sec>
    </sec>
    <sec id="sec-5">
      <title>5. Discussion and Outlook</title>
      <sec id="sec-5-1">
        <title>5.1. Future Work</title>
        <p>For future research work, manual interpolating should be carried out on the missing values
dataset to determine whether there is a significant change in the results. Furthermore additional
factors such as the weather and proximity to coal - fired power plants can be considered.</p>
      </sec>
      <sec id="sec-5-2">
        <title>5.2. Evaluation</title>
        <p>The evaluation is carried out by considering the actual values of the sensor data. The results
were compared on an hourly basis by taking the mean of the first and last values in a given
hour. The RMSE for sensors were Sensor 4 (22.14%), Sensor 7 (5.77%) and Sensor 10 (6.99%).</p>
        <sec id="sec-5-2-1">
          <title>Sensors</title>
        </sec>
        <sec id="sec-5-2-2">
          <title>Sensor#4</title>
        </sec>
        <sec id="sec-5-2-3">
          <title>Sensor#7</title>
        </sec>
        <sec id="sec-5-2-4">
          <title>Sensor#10 RMSE</title>
        </sec>
      </sec>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <surname>T.-L. N</surname>
            .-T. T.-
            <given-names>B. N.</given-names>
          </string-name>
          <string-name>
            <surname>Minh-Son</surname>
            <given-names>Dao</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Thanh-Hai Dang</surname>
          </string-name>
          , D.-
          <string-name>
            <surname>T.</surname>
          </string-name>
          Dang-Nguyen,
          <article-title>Overview of mediaeval 2022 urban air: Urban life and air pollution, mediaeval</article-title>
          , bergen, norway,
          <fpage>13</fpage>
          -
          <lpage>15</lpage>
          January
          <year>2022</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>S. J.</given-names>
            <surname>Taylor</surname>
          </string-name>
          , B. Letham, Forecasting at scale,
          <source>The American Statistician</source>
          <volume>72</volume>
          (
          <year>2018</year>
          )
          <fpage>37</fpage>
          -
          <lpage>45</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>T.-V.</given-names>
            <surname>La</surname>
          </string-name>
          , M.-
          <string-name>
            <given-names>S.</given-names>
            <surname>Dao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Tejima</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R. U.</given-names>
            <surname>Kiran</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Zettsu</surname>
          </string-name>
          ,
          <article-title>Improving the awareness of sustainable smart cities by analyzing lifelog images and iot air pollution data</article-title>
          ,
          <source>in: 2021 IEEE International Conference on Big Data (Big Data)</source>
          , IEEE,
          <year>2021</year>
          , pp.
          <fpage>3589</fpage>
          -
          <lpage>3594</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <surname>P.-B. Vo</surname>
            , T.-D. Phan, M.-
            <given-names>S.</given-names>
          </string-name>
          <string-name>
            <surname>Dao</surname>
            ,
            <given-names>K.</given-names>
          </string-name>
          <string-name>
            <surname>Zettsu</surname>
          </string-name>
          ,
          <article-title>Association model between visual feature and aqi rank using lifelog data</article-title>
          ,
          <source>in: 2019 IEEE International Conference on Big Data (Big Data)</source>
          ,
          <year>2019</year>
          , pp.
          <fpage>4197</fpage>
          -
          <lpage>4200</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>D.</given-names>
            <surname>Duong</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Q.</given-names>
            <surname>Le</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.-L.</given-names>
            <surname>Nguyen-Tai</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            <surname>Nguyen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Dao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Nguyen</surname>
          </string-name>
          ,
          <article-title>An Efective AQI Estimation Using Sensor Data</article-title>
          and
          <string-name>
            <given-names>Stacking</given-names>
            <surname>Mechanism</surname>
          </string-name>
          ,
          <year>2021</year>
          . doi:
          <volume>10</volume>
          .3233/FAIA210040.
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>