You are on page 1of 28

_p

TRAINING KIT – ATMO01


DFSDFGAGRIAGRAGRI
AIR QUALITY MONITORING WITH SENTINEL-5p
Research and User Support for Sentinel Core Products

The RUS Service is funded by the European Commission, managed by the European Space
Agency and operated by CSSI and its partners.
Authors would be glad to receive your feedback or suggestions and to know how this
material was used. Please, contact us on training@rus-copernicus.eu
Cover image credits: ESA

The following training material has been prepared by Serco Italia S.p.A. within the RUS
Copernicus project. The authors acknowledge the support of NOVELTIS in the creation of this
material.
Date of publication: June 2019
Version: 1.1

Suggested citation:
Serco Italia SPA (2019). Air Quality Monitoring with Sentinel-5p (version 1.1). Retrieved from
RUS Lectures at https://rus-copernicus.eu/portal/the-rus-library/learn-by-yourself/

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0


International License.

DISCLAIMER

While every effort has been made to ensure the accuracy of the information contained in this publication, RUS
Copernicus does not warrant its accuracy or will, regardless of its or their negligence, assume liability for any
foreseeable or unforeseeable use made of this publication. Consequently, such use is at the recipient’s own risk on
the basis that any use by the recipient constitutes agreement to the terms of this disclaimer. The information
contained in this publication does not purport to constitute professional advice.

2
Table of Contents
1 Introduction to RUS ......................................................................................................................... 4
2 Air quality – background ................................................................................................................. 4
3 Training ............................................................................................................................................ 4
3.1 Data used ................................................................................................................................. 4
3.2 Software in RUS environment ................................................................................................. 4
4 Register to RUS Copernicus ............................................................................................................. 5
5 Request a RUS Copernicus Virtual Machine .................................................................................... 6
6 Step by step ................................................................................................................................... 10
6.1 Data download – ESA SciHUB ................................................................................................ 10
6.2 VISAN – open and explore data............................................................................................. 12
6.3 Level 3 Aerosol Index gridded product.................................................................................. 17
6.3.1 HARP bin_spatial operation .......................................................................................... 17
6.3.2 HARP derive operation .................................................................................................. 17
6.3.3 HARP Comparison filter operation ................................................................................ 17
6.3.4 HARP Convert Command line tool ................................................................................ 18
6.4 Daily averaged Aerosol Index product .................................................................................. 19
6.5 Monitoring fire using Aerosol Index ...................................................................................... 21
6.6 Tropospheric vertical NO2 column........................................................................................ 23
6.6.1 Daily averaged tropospheric NO2 vertical column ........................................................ 23
6.6.2 Monthly averaged tropospheric NO2 vertical column................................................... 24
7 Further reading and resources ...................................................................................................... 28

3
1 Introduction to RUS
The Research and User Support for Sentinel core products (RUS) service provides a free and open
scalable platform in a powerful computing environment, hosting a suite of open source toolboxes
pre-installed on virtual machines, to handle and process data derived from the Copernicus Sentinel
satellites constellation.
In this tutorial, we will employ RUS to monitor air quality using Sentinel-5p products as input data.

2 Air quality – background


Air pollution is a major environmental health problem
that affects people in developed and developing
countries alike. With millions of people dying
prematurely every year as a direct result of poor air
quality, it has never been more important to monitor the
air we breathe.
Pollutants enter the air from a range of sources, although
they are mainly a result of motor vehicle and industrial
Air pollution. Credits: Wikipedia Commons combustion processes. Governments and decision-
makers rely heavily on satellite data and computer models to show how pollution accumulates and
how it is carried in the air so that they can develop appropriate mitigation strategies.
A few years ago, the European Union (EU) started an ambitious program, Copernicus, which includes
the launch of a new family of earth observation satellites known as Sentinels. Sentinel-5p provides
timely data on a multitude of trace gases (CO, NO22, SO22, O33, aerosols…) with a great accuracy
and spatial resolution. It also provides measurement continuity with precedent and ongoing
atmospheric spatial missions (OMI, IASI and SCHIAMACHY).

3 Training
Approximate duration of this training session is one hour.
The Training Code for this tutorial is ATMO01. If you wish to practice the exercise described below
within the RUS Virtual Environment, register on the RUS portal and open a User Service request
from Your RUS service > Your dashboard.

3.1 Data used


• 13 Sentinel-5p images acquired on May 17th 2019
• Pre-processed data stored locally
@/shared/Training/ATMO01_AirQuality_Global/AuxData/

3.2 Software in RUS environment


Internet browser, BEAT + QGIS

4
4 Register to RUS Copernicus
To repeat the exercise using a RUS Copernicus Virtual Machine (VM), you will first have to register as
a RUS user. For that, go to the RUS Copernicus website (www.rus-copernicus.eu) and click on
Login/Register in the upper right corner.

Select the option Create my Copernicus SSO account and then fill in ALL the fields on the Copernicus
Users’ Single Sign On Registration. Click Register.

Within a few minutes you will receive an e-mail with activation link. Follow the instructions in the e-
mail to activate your account.
You can now return to https://rus-copernicus.eu/, click on Login/Register, choose Login and enter
your chosen credentials.

5
Upon your first login you will need to enter some details. You must fill all the fields.

5 Request a RUS Copernicus Virtual Machine


Once you are registered as a RUS user, you can request a RUS Virtual Machine to repeat this exercise
or work on your own projects using Copernicus data. For that, log in and click on Your RUS Service →
Your Dashboard.

6
Click on Request a new User Service to request your RUS Virtual Machine. Complete the form so that
the appropriate cloud environment can be assigned according to your needs.

If you want to repeat this tutorial (or any previous one) select the one(s) of your interest in the
appropriate field.

Complete the remaining steps, check the terms and conditions of the RUS Service and submit your
request once you are finished.

7
Further to the acceptance of your request by the RUS Helpdesk, you will receive a notification email
with all the details about your Virtual Machine. To access it, go to Your RUS Service → Your
Dashboard and click on Access my Virtual Machine.

8
Fill in the login credentials that have been provided to you by the RUS Helpdesk via email to access
your RUS Copernicus Virtual Machine.

This is the remote desktop of your Virtual Machine.

9
6 Step by step
6.1 Data download – ESA SciHUB
Before starting the exercise, make sure you are registered in the Copernicus Open Access Hub so that
you can access the free data provided by the Sentinel satellites.
Go to https://scihub.copernicus.eu/

Go to Open Hub. If you do not have an account, sign up in the upper right corner, fill in the details
and click register.

You will receive a confirmation email on the e-mail address you have specified: open the email and
click on the link to finalize the registration.

Once your account is activated – or if you already have an account – log in (See NOTE 1).

10
NOTE 1: At the time of creation of this tutorial (June 2019), Sentinel-5p products are still only accessible
through the Sentinel-5p Pre-Operations Data Hub. To download S-5p products, log in using s5pguest as
username and password. In the near future, products will be moved to the regular Copernicus Open
Access Hub where you will be requested to log in with your own credentials. For that, create an account
as explained previously.

Since we are targeting the production of global maps, we do not need to define a specific study area
in our search. Open the search menu by clicking to the left part of the search bar ( ) and specify the
parameters below. Press the search button ( ) after that.
Sensing period: From 2019/05/17 to 2019/05/17
Check Mission: Sentinel-5p
Product type: L2__AER_AI
Processing level: L2
Timeliness: Offline

In this case the search returns 13 results. Download all the products (products will be saved in
/home/rus/Downloads) and move them to the following path.
Path: /shared/Training/ATMO01_AirQuality_Global/Original/

11
In this case the search returns 13 results. Download all the products (products will be saved in
/home/rus/Downloads) and move them to the following path (See NOTE 2 and 3).
Path: /shared/Training/ATMO01_AirQuality_Global/Original/

NOTE 2: Sentinel-5p counts 14 orbits per day. Due to the starting (d) and end acquisition time (d+1)
during the last orbit, when looking for all the products of a day the result may output 13 products
instead of 14. To complete the global coverage, you may need to increase by one day the sensing time
to find the last product.

NOTE 3: Sentinel-5p products are delivered as netCDF files. The Network Common Data Form, or
netCDF, is an interface to a library of data access functions for storing and retrieving data in the form of
arrays. An array is an n-dimensional (where n is 0, 1, 2, ...) rectangular structure containing items which
all have the same data type (e.g., 8-bit character, 32-bit integer). A scalar (simple single value) is a 0-
dimensional array. a large amount of free software as well as commercial or licensed packages is
available at the UniData website.

6.2 VISAN – open and explore data


In this exercise we will use the Basic Envisat Atmospheric Toolbox (BEAT) toolbox to analyse the
Sentinel-5p data and run our analysis. The ESA Atmospheric Toolbox project (BEAT) aims to provide
scientists with tools for ingesting, processing, and analyzing atmospheric remote sensing data.
The project consists of several components, with the main components being CODA, HARP, and
VISAN. These components are made available by means of several software packages.
- CODA: allows direct reading access to product data, supporting a very wide range of
products. All product file data is accessible via the CODA C library. On top of this, there are
several interfaces available to directly ingest product data using e.g. Fortran, IDL, MATLAB,
and Python.

- HARP: toolset for ingesting, processing and inter-comparing satellite or model data against
correlative data. The toolset provides a set of command line tools, a library of analysis
functions, and direct import/export interfaces for Python, IDL, and MATLAB. By appropriately

12
chaining calls to the HARP command line tools one can preprocess satellite and correlative
data such that the two datasets that need to be compared end up having the same
temporal/spatial grid, same data format/structure, and same physical unit.

- VISAN: cross-platform visualization and analysis application for atmospheric data. The
application uses the Python language as the means through which you provide commands to
the application. The Python interfaces for CODA and HARP are included so you can directly
ingest product data from within VISAN (HARP interfaces will be added once the HARP Python
interface becomes available). Finally, VISAN provides some very powerful visualization
functionality for 2D and world plots.
The primary instruments supported by BEAT are Tropomi (Sentinel-5P), GOME-2 and IASI (MetOp),
OMI, TES and MLS (Aura), GOMOS, MIPAS, and SCIAMACHY (ENVISAT), and GOME (ERS-2). More
information on the BEAT project can be found at http://www.stcorp.nl/beat/

In the desktop, double click on the VISAN icon - - to open it. The command line interface will
appear together with the help window (if it is the first time you use VISAN, read the help window and
close it afterwards).

In the File menu, click on Browse Product, navigate to the following path and open the first Sentinel-
5p product – S5P_OFFL_L2__AER_AI_20190517T005850_20190517T024020_08238_01_010301_20190523T002750.nc
Path: /shared/Training/ATMO01_AirQuality_Global/Original/

13
Once opened, VISAN gives you the option to navigate the Sentinel-5p product (PRODUCT folder) and
access metadata (METADATA folder) information. The PRODUCT folder contains data of interest as
2D arrays (Aerosol index, error estimates, quality index…). The SUPPORT_DATA subfolder contains
additional and auxiliary data (geolocation flags, lat/lon bounds, satellite position, etc.). Within the
PRODUCT folder, select the aerosol_index_340_380 file.

Click on the 2D Grid to visualize the 2D array. For each variable, it is possible to check the whole
product (all rows/columns), a specific row/column and its attributes (Attributes tab).
Next, click on the 2D Plot. Set the x-axis coordinates to 0; 614; 0 to visualize a 2D plot.

14
After visualizing the data as an array and 2D graph, we will create a 3D visualization of the product.
Close the browse product window on the main VISAN page and go to File -> Harp Import. This menu
will create the Python command to perform an import on a product.
In the Path option, navigate to the following path and select the same product as before (Sixth from
the top - S5P_OFFL_L2__AER_AI_20190517T092621_20190517T110751_08243_01_010301_20190523T085237.nc)
Path: /shared/Training/ATMO01_AirQuality_Global/Original/
The Operations tab gives the possibility to provide a single string where individual operations are
separated by a semi colon (i.e. ‘latitude>-55[degree_north];bin()’). For this exercise, leave the
Operations tab empty (See NOTE 4).

NOTE 4: HARP provides a simple expression syntax with which one can specify operations that need to
be performed on a product. A list of operations is always provided as a single string where individual
operations are separated by a semi-colon (;). Each operation can be either a comparison filter, a
membership test filter, or a function call. Strings used in operations should be quoted with double
quotes. More information at: http://stcorp.github.io/harp/doc/html/operations.html

The Ingestion options gives the option to ingest different variables from the Sentinel-5p product to
the HARP converted product (i.e. which aerosol index to keep in the ingested product). For this
exercise, leave the Ingestion options empty (See NOTE 5).

NOTE 5: HARP can ingest data from various types of products. HARP will try to automatically determine
the product type of each file that you pass to the ingest function. An error will be raised if the product
type of a file cannot be determined. For each ingestion, HARP will return a single HARP product. Each
variable in a HARP product represents a specific quantity (e.g. O3 number density, cloud fraction,
altitude, longitude, latitude, time, et cetera). You can customize which variables you want to include
using the include() and exclude() operations that can be passed to the ingest function. More information
at: http://stcorp.github.io/harp/doc/html/ingestions/

Next, in the Variable name tab, write S5p_AER to name the imported product. Finally, click Import.
The python command used can be seen in the main VISAN window.

15
Once the product has been imported, we can use specific code to manipulate and visualize the data.
In the VISAN window write the following command and press enter. (See NOTE 6).

NOTE 6: Much of VISAN's functionality is provided by Python and the Numpy package, which are both
part of VISAN. For an overview of the functions provided please look at the Python and Numpy
documentation. More information at http://www.stcorp.nl/beat/doc/visan/reference.html

wplot(S5p_AER)

To move on the VISAN World Plot window, maintain the left button of your mouse and move it in the
appropriate direction. To zoom in/out, maintain the right button of the mouse and move it to the
top/bottom of the window. Invalid data is present in the poles.
16
You can change the display settings (color table, color bar, projection, etc.). For that, go to View ->
Properties in the plot window and change the parameters according to your preference. When
changing a parameter, press the ENTER key of your keyboard to validate the change.

6.3 Level 3 Aerosol Index gridded product


With the objective to create a world map of the aerosol index, we first need to process the Sentinel-
5p Level 2 products to keep a single grid per orbit (level 3 – L3). The conversion is done combining
several operators in a single call. The sub-chapters below give more information on each step.

6.3.1 HARP bin_spatial operation


The HARP bin_spatial() tool maps all time samples onto a regular spatial lat/lon grid for all variables
in a product. It follows a specific sequence of parameters shown below:

bin_spatial(lat_edge_length,lat_edge_offset,lat_edge_step,lon_edge_length,lon_edge_offset,lon_ed
ge_step)

For example:
bin_spatial(271,-55,0.5,721,-180,0.5)

The choice of the spatial resolution (lat/lon_edge_step) and the boundaries (lat/lon_edge_offset,
lat/lon_edge_length) can be chosen by the user. Please note that a higher spatial resolution and a
larger area of interest increase the processing time (See NOTE 7).

NOTE 7: if only lat/lon center coordinates of ground pixels in the products, the HARP bin_spatial() tool
performs an average of all values whose center point falls in the grid cell
𝑃𝑖𝑥𝑒𝑙3 + 𝑃𝑖𝑥𝑒𝑙4
𝑉𝑎𝑙𝑢𝑒 =
2
Sentinel-5p products are delivered with lat/lon_bounds variable. In this case, the HARP bin_spatial()
tool proceeds to an area weighted average based on ground pixel areas and grid cell intersection (a i)

∑5𝑖=1 𝑎𝑖 ∗ 𝑃𝑖𝑥𝑒𝑙𝑖
5 𝑉𝑎𝑙𝑢𝑒 =
∑5𝑖=1 𝑎𝑖
3

4
Grid pixel
1
2 S-5p ground pixel

6.3.2 HARP derive operation


When spatially binning a product with bin_spatial(), only the lat/lon_bounds of the grid cells will be
saved in the output product. To write the lat/lon center coordinates of the spatial grid in the output
we use the derive operation.

Example: ‘derive(longitude{longitude}); derive(latitude{latitude})’

6.3.3 HARP Comparison filter operation


This operator filters a dimension for all variables in the product such that items for which the value of
the provided variable does not match the expression get excluded.

17
Example: ‘latitude>-55 [degree_north]; longitude <70 [degree_east]’

6.3.4 HARP Convert Command line tool


Once the concept of the steps we will combine is clear, we will use the command line tool to
combine all of them and apply it to our product. The tool allows to define a list of operations (in our
case, bin_spatial() ; derive() ; comparison) to apply to each product using the -a parameter, to define
ingestion options using the -o parameter and to define the output format using the -f parameter (the
default NETCDF format will be used in this exercise).

Example:
-a ‘bin_spatial(…);derive(…)’
-o ‘wavelength_ratio=354_338nm’

harpconvert -a ‘operations_list’ -o ‘ingestion_option’ input_file output_Directory/output_file

To run the command, go to the following path where all the input Sentinel-5p level 2 UV Aerosol
Index products are stored. Right click anywhere on the folder and select Open Terminal Here.
Path: /shared/Training/ATMO01_AirQuality_Global/Original/

Copy/Paste the following command in the Terminal window and press Enter to run it. The output
directory where the result will be saved has been set to the following path:
Path: /shared/Training/ATMO01_AirQuality_Global/Processing/L3_GriddedProducts/

harpconvert -a 'latitude > -55 [degree_north]; latitude < 80 [degree_north]; bin_spatial(271,-55,0.5,7


21,-180,0.5); derive(latitude {latitude}); derive(longitude {longitude})' /shared/Training/ATMO01_Air
Quality_Global/Original/S5P_OFFL_L2__AER_AI_20190517T092621_20190517T110751_08243_01_0
10301_20190523T085237.nc /shared/Training/ATMO01_AirQuality_Global/Processing/L3_GriddedPr
oducts/Converted_Product.nc

Once run, go to File -> Harp import in the main VISAN window to import the output product and
visualize it. In the file path, navigate to the output path specify before and select the output product.

18
Leave the operations and ingestion options as default and change the variable name to AER_L3. Next,
click Import.

As before, once the product has been imported, we can use specific code to manipulate and visualize
the data. In the VISAN window write the following command and press enter (See NOTE 8).

wplot(AER_L3.latitude.data,AER_L3.longitude.data,AER_L3.absorbing_aerosol_index.data)

NOTE 8: Go to View -> Properties to change the display settings such as the color bar name, min/max
values, color palette, etc. in the

6.4 Daily averaged Aerosol Index product


Sentinel-5p Offline products are delivered as single file orbits. To create a world map using the all the
products available within a day, they all need to be processed as explained before and merged. Once
each Sentinel-5p product is processed to keep a single grid per orbit, we will concatenate all the
output files to create a World Map.
For this we will use the HARPMERGE operator, which combines multiple products from files or
directory by appending them across the time dimension and storing the result into a single output
file. When running HARPMERGE, we will include to code to:
- Define a list of operations to apply to each product before it is appended (-a): same
processing as HARPCONVERT done in the previous chapter
- Define a list of operations to apply to the merged product (-ap): operation to properly export
the merged product. The bin() operation will average each of the lat/lon grid cells over time
19
so that we have {1,lat,lon} elements. The squash(time, (latitude, longitude)) will remove the
time=1 dimension created by the bin() operation from lat/lon variables to have proper
georeferenced products for further use in other software (i.e. QGIS, Panoply…)
- In addition, ingestion options (-o) and output format (-f) could be defined

harpmerge -ap ‘operations_list’ -a ‘operations_list’ -o ‘ingestion_option’ input_file output_Directory/


output_file

Go to the following path where all the input Sentinel-5p level 2 UV Aerosol Index products are
stored. Right click anywhere on the folder and select Open Terminal Here.
Path: /shared/Training/ATMO01_AirQuality_Global/Original/

Copy/Paste the following command in the Terminal window and press Enter to run it. The code will
create an average World Map for latitudes between [-55,80] for UV Aerosol Index on the 17/05/2019
for the 354/388 wavelength pair. The output directory where the result will be saved has been set to
the following path:
Path: /shared/Training/ATMO01_AirQuality_Global/Processing/L3_GriddedProducts/

harpmerge -ap 'bin(); squash(time, (latitude,longitude))' -a 'latitude > -55 [degree_north]; latitude < 8
0 [degree_north]; bin_spatial(271,-55,0.5,721,-180,0.5); derive(longitude {longitude}); derive(latitude
{latitude})' S5P_OFFL_L2__AER*.nc /shared/Training/ATMO01_AirQuality_Global/Processing/L3_Gri
ddedProducts/Global_AER_L3.nc

Once run, go to File -> Harp import in the main VISAN window to import the output product and
visualize it. In the file path, navigate to the output path specify before and select the output product.
Leave the operations and ingestion options as default and change the variable name to L3_Global.
Next, click Import.

20
As before, once the product has been imported, we can use specific code to manipulate and visualize
the data. In the VISAN window write the following command and press enter.

wplot(L3_Global.latitude.data,L3_Global.longitude.data,L3_Global.absorbing_aerosol_
index.data)

Single orbit products have been re-gridded and properly concatenated into a single averaged Aerosol
Index product (See NOTE 9).

NOTE 9: For no apparent reasons some spots over the ocean have high aerosol index values caused by
the sun glint. Pixels affected by sun glint can be filtered out by applying a quality filter when executing
the HARPMERGE command line tool (-absorbing_aerosol_index_validity > 80) (0: worst quality | 100:
full quality).

6.5 Monitoring fire using Aerosol Index


Taking advantage of the Sentinel-5p temporal resolution, in this section we will explore the
capabilities to monitor a fire event in California (U.S.A.) using the aerosol index level 2 product.
The 2018 wildfire season was the deadliest and most destructive wildfire season on record in
California, with a total of 8,527 fires burning an area of 766,439 ha. In November 2018, strong winds
aggravated conditions in another round of large, destructive fires that occurred across the state. This
new batch of wildfires included the Woolsey Fire and the Camp Fire, becoming both California's
deadliest and most destructive wildfire on record.
Close the Terminal window. In the file browser, navigate to the following path, right click anywhere
in the folder and click on Open Terminal Here (See NOTE 10).

Path: /shared/Training/ATMO01_AirQuality_Global/Original/Fire_California/

NOTE 10: Images for this exercise must be downloaded in advanced. Go to 8.1 Extra data download –
Fire monitoring and follow the instructions.

21
Copy/Paste the following command in the Terminal window and press Enter to run it. The output
directory where the result will be saved has been set to the following path:
Path: /shared/Training/ATMO01_AirQuality_Global/Processing/Fire_California/

harpmerge -a 'latitude > 32 [degree_north]; latitude < 42 [degree_north]; longitude > -126 [degree_e
ast]; longitude < -116 [degree_east]; absorbing_aerosol_index_validity>80; bin_spatial(101,32,0.1,10
1,-126,0.1); derive(longitude {longitude});derive(latitude {latitude})' S5P_OFFL_L2__AER*.nc /shared/
Training/ATMO01_AirQuality_Global/Processing/Fire_California/l3_AER_AI_20191102_20191121.nc

In this case, the -ap ‘bin(); squash(time, (latitude,longitude))’ command is not used as we want to
keep the time dimension in the merged product to create an animated plot.
Next, go to File -> Harp import in the VISAN window to import the output product and visualize it. In
the file path, navigate to the output path specify before and select the output product. Leave the
operations and ingestion options as default and change the variable name to Fire. Next, click Import.

As before, once the product has been imported, we can use specific code to manipulate and visualize
the data. In the VISAN window write the following command and press enter.

wplot(Fire)

To create the animated plot, in the plot window go to View -> Properties. In the Plot tab, change the
title to: Camp fire (California 02-21 November 2018) UV Aerosol Index. Next, navigate to the Camp
Fire location (California, U.S.A.) and zoom in using your mouse (you can also set the coordinates as
shown in the screenshot).

In the Dataset -> Color Bar tab, change the following parameters:
- Color bar tittle: Absorbing aerosol index (354/388 nm)
- Number of labels: 5
- Range Min: -5
- Range Max: 5
In the Attributes tab you can visualize the timeframe of the product being displayed.

22
At the bottom of the VISAN world plot window, select the Loop option. Set the Speed to 1 and press
Play. The plot displays the evolution of the generated aerosol plume.

6.6 Tropospheric vertical NO2 column

6.6.1 Daily averaged tropospheric NO2 vertical column


To explore the capabilities of Sentinel-5p to detect and monitor other air pollutants, we will create a
daily averaged tropospheric vertical NO2 column using Sentinel-5p level 2 NO2 products. For that,
close the current Terminal window. Open a file browser and navigate to the following path (See
NOTE 11).

NOTE 11: Images for this exercise must be downloaded in advanced. Go to 8.2 Extra data download –
NO2 Monitoring and follow the instructions.

Path: /shared/Training/ATMO01_AirQuality_Global/Original/N02/
Right click anywhere in the folder and click Open Terminal Here.
Copy/Paste the following command in the Terminal window and press Enter to run it. The output
directory where the result will be saved has been set to the following path:
Path: /shared/Training/ATMO01_AirQuality_Global/Processing/NO2/

harpmerge -ap 'bin(); squash(time, (latitude,longitude))' -a 'latitude > -55 [degree_north]; latitude < 6
0 [degree_north]; tropospheric_NO2_column_number_density_validity > 75; bin_spatial(231,-55,0.5,
721,-180,0.5); derive(longitude {longitude});derive(latitude {latitude})' S5P_OFFL_L2__NO2*.nc /shar
ed/Training/ATMO01_AirQuality_Global/Processing/NO2/l3_NO2_20190124_quality_75.nc

The command builds a daily averaged world map for latitudes between [-55,60] of tropospheric
vertical column of NO2 on 24/01/2019 with full quality data. The value of the
tropospheric_NO2_column_number_density_validity is set to 75 as it is the recommended pixel filter
to remove cloud/snow/ice covered scenes, errors and problematic retrieval.

23
Once run, go to File -> Harp import in the main VISAN window to import the output product and
visualize it. In the file path, navigate to the output path specify before and select the output product.
Leave the operations and ingestion options as default and change the variable name to NO2. Next,
click Import.

As before, once the product has been imported, we can use specific code to manipulate and visualize
the data. In the VISAN window write the following command and press enter.

wplot(NO2)

Single orbit products have been re-gridded and properly concatenated into a single averaged
tropospheric vertical column of NO2 products. To improve the visualization, change the Min/Max
values of the color bar to 0 and 0.000075 mol/m2 respectively.

Due to the air pollution present in urban areas, the world’s major cities are highlighter (specially over
China). Furthermore, due to cloud coverage, large invalid areas are visible.

6.6.2 Monthly averaged tropospheric NO2 vertical column


In the last step, we will derive a monthly averaged tropospheric vertical NO2 column using Sentinel-
5p level 2 NO2 products. For that, close the current Terminal window. Open a file browser and
navigate to the following path. There, all averaged daily maps of tropospheric vertical column of NO2
for January 2019 have been created following the same method as before.
Path: /shared/Training/ATMO01_AirQuality_Global/Original/NO2_GlobalAverage/
Right click anywhere in the folder and click Open Terminal Here.

24
Copy/Paste the following command in the Terminal window and press Enter to run it. The output
directory where the result will be saved has been set to the following path:
Path: /shared/Training/ATMO01_AirQuality_Global/Processing/NO2/Global/

harpmerge -ap 'bin(); squash(time, (latitude,longitude))' l3_201901*.nc /shared/Training/ATMO01_A


irQuality_Global/Processing/NO2/Global/l3_NO2_201901_quality_75.nc

The command builds a monthly averaged world map for latitudes between [-55,60] of tropospheric
vertical column of NO2
Once run, go to File -> Harp import in the main VISAN window to import the output product and
visualize it. In the file path, navigate to the output path specify before and select the output product.
Leave the operations and ingestion options as default and change the variable name to NO2_month.
Next, click Import.

As before, once the product has been imported, we can use specific code to manipulate and visualize
the data. In the VISAN window write the following command and press enter.

wplot(NO2_month)

Daily averaged products have been properly concatenated into a single monthly averaged
tropospheric vertical column of NO2 products. To improve the visualization, change the Min/Max
values of the color bar to 0 and 0.000075 mol/m2 respectively.

25
8 Extra steps
8.1 Extra data download – Fire monitoring
To download the data for the fire monitoring exercise go to the Sentinel-5p Pre-Operations Data
Hub, log in as explained before and copy paste the following product names in the search bar. Then,
click on search and download to product. Once downloaded (in home/rus/downloads) move it to the
following path.

Path: /shared/Training/ATMO01_AirQuality_Global/Original/Fire_California/

Date Product ID

2018-11-02 S5P_OFFL_L2__AER_AI_20181102T204153_20181102T222322_05469_01_010200_20181108T200727

2018-11-03 S5P_OFFL_L2__AER_AI_20181103T202245_20181103T220415_05483_01_010200_20181109T194206

2018-11-04 S5P_OFFL_L2__AER_AI_20181104T200338_20181104T214507_05497_01_010200_20181110T192244

2018-11-05 S5P_OFFL_L2__AER_AI_20181105T194430_20181105T212600_05511_01_010200_20181111T190324

2018-11-06 S5P_OFFL_L2__AER_AI_20181106T192523_20181106T210652_05525_01_010200_20181112T184406

2018-11-07 S5P_OFFL_L2__AER_AI_20181107T204745_20181107T222915_05540_01_010200_20181113T201448

2018-11-08 S5P_OFFL_L2__AER_AI_20181108T202838_20181108T221007_05554_01_010200_20181114T195528

2018-11-09 S5P_OFFL_L2__AER_AI_20181109T200931_20181109T215100_05568_01_010200_20181115T193606

2018-11-10 S5P_OFFL_L2__AER_AI_20181110T195023_20181110T213153_05582_01_010200_20181116T191647

2018-11-11 S5P_OFFL_L2__AER_AI_20181111T193116_20181111T211246_05596_01_010200_20181117T185728

2018-11-12 S5P_OFFL_L2__AER_AI_20181112T191210_20181112T205339_05610_01_010200_20181118T183807

2018-11-14 S5P_OFFL_L2__AER_AI_20181114T201526_20181114T215655_05639_01_010200_20181120T193926

26
2018-11-16 S5P_OFFL_L2__AER_AI_20181116T193712_20181116T211842_05667_01_010200_20181122T185737

2018-11-17 S5P_OFFL_L2__AER_AI_20181117T191806_20181117T205936_05681_01_010200_20181123T184418

2018-11-18 S5P_OFFL_L2__AER_AI_20181118T204029_20181118T222159_05696_01_010200_20181124T200555

2018-11-20 S5P_OFFL_L2__AER_AI_20181120T200217_20181120T214347_05724_01_010200_20181126T192906

2018-11-21 S5P_OFFL_L2__AER_AI_20181121T194311_20181121T212441_05738_01_010200_20181127T191033

8.2 Extra data download – NO2 Monitoring


To download the data for the NO2 monitoring exercise go to the Sentinel-5p Pre-Operations Data
Hub, log in as explained before and copy paste the following product names in the search bar. Then,
click on search and download to product. Once downloaded (in home/rus/downloads) move it to the
following path.

Path: /shared/Training/ATMO01_AirQuality_Global/Original/N02/
Date Product ID
S5P_OFFL_L2__NO2____20190124T010650_20190124T024820_06635_01_010202_20190130T024317

S5P_OFFL_L2__NO2____20190124T024820_20190124T042951_06636_01_010202_20190130T043730

S5P_OFFL_L2__NO2____20190124T042951_20190124T061121_06637_01_010202_20190130T061522

S5P_OFFL_L2__NO2____20190124T061121_20190124T075251_06638_01_010202_20190130T080926

S5P_OFFL_L2__NO2____20190124T075251_20190124T093421_06639_01_010202_20190130T094112

S5P_OFFL_L2__NO2____20190124T093421_20190124T111551_06640_01_010202_20190130T113605

S5P_OFFL_L2__NO2____20190124T111551_20190124T125722_06641_01_010202_20190130T143915
2019-01-24
S5P_OFFL_L2__NO2____20190124T125722_20190124T143852_06642_01_010202_20190130T151234

S5P_OFFL_L2__NO2____20190124T143852_20190124T162022_06643_01_010202_20190130T161125

S5P_OFFL_L2__NO2____20190124T162022_20190124T180152_06644_01_010202_20190130T182515

S5P_OFFL_L2__NO2____20190124T180152_20190124T194322_06645_01_010202_20190130T201724

S5P_OFFL_L2__NO2____20190124T194322_20190124T212452_06646_01_010202_20190130T214447

S5P_OFFL_L2__NO2____20190124T212452_20190124T230622_06647_01_010202_20190131T080338

S5P_OFFL_L2__NO2____20190124T230622_20190125T004753_06648_01_010202_20190131T004111

27
THANK YOU FOR FOLLOWING THE EXERCISE!

9 Further reading and resources


Sentinel-5 User Guide
https://sentinel.esa.int/web/sentinel/user-guides/sentinel-5p-tropomi

Sentinel-5 Technical Guide


https://sentinel.esa.int/web/sentinel/technical-guides/sentinel-5p/products-algorithms

Tropomi
http://www.tropomi.eu/

FOLLOW US!!!

@RUS-Copernicus

RUS-Copernicus

RUS-Copernicus

RUS Copernicus Training

RUS-Copernicus website
website
RUS-Copernicus Training website

28

You might also like