How to Georeference and Convert NRT AMSR2 Snow Water Equivalent Polar EASE-Grid Data to GeoTIFF Format using Python and ArcGIS

The near real-time (NRT) Land Atmosphere Near real-time Capability for EOS (LANCE) AMSR2 Daily Global Snow Water Equivalent (SWE) EASE-Grids dataset contains SWE and quality assurance flag information for the Northern and Southern Hemispheres. These data are available in HDF-EOS5 format requiring georeferencing in order to display according to the NSIDC EASE-Grid format. This data recipe employs Python to georeference and create four GeoTIFFs of the SWE and quality assessment flag layers within the HDF-EOS5 files. The data are brought into ArcMap where the projection is defined to enable further data processing, analysis and map making. This data recipe requires a pre-installed version of ArcMap, Python and the necessary Python packages.

Data Recipe Type
Data Format Conversion
Supporting Software Information
Python Script Open Source
ArcMap 10.2+ Restricted, license required
This data recipe uses the NRT LANCE AMSR2 Daily L3 Global SWE dataset. More information and additional resources about this dataset can be accessed here. Please note that because this is a LANCE dataset, data files are only available for the past 14 days. 
To follow along with the steps below, pre-installed versions of Python and ArcMap 10.2 or greater are required. Additionally, please install the following Python packages to run the data recipe: GDAL, NumPy, tables and pyproj.
Step 1

To download the data needed for this data recipe, a free NASA Earthdata user account is required. If you do not have an account, you will first need to create one.
Once your NASA Earthdata account has been created, you can download a HDF-EOS5 NRT LANCE AMSR2 Daily L3 Global SWE datafile to use with this data recipe.  Simply follow this link to enter your account information, select and download a file.  Save the file to a desired location on your computer.

Step 2

Open the Python environment installed on your computer and make sure the required Python packages outlined in the “How to Use” section are installed.

Step 3

Navigate to the GHRC GitHub page and download the Python script labeled “”.  Save this script to your computer, then open the file within your Python environment.

Step 4

Navigate to the folder on your computer where you have saved the AMSR2 SWE HDF-EOS5 data file. From the address bar, copy the file path as shown below.


Paste the file path within the quotation marks for the variable “infile” highlighted in blue below.  For Python, the backslashes need to be changed to forward slashes.  At the end of the file path, add the filename of the AMSR2 SWE file after the last forward slash as shown.

Step 5

When the Python code is run, it will create and save four GeoTIFF files to a folder on your computer. Create or locate a folder on your computer where you would like these GeoTIFF files to be saved. As done in Step 3, copy the file path and paste it within the code in the area highlighted in blue below.  Make sure a forward slash is included at the end of the file path.

Step 6

Documentation is provided in the Python code to outline what each section of  code does.  The code defines which data parameter layers in the HDF-EOS5 file will be used to create the GeoTIFF files.  For this data recipe we are extracting the following layers: Flags_NorthernDaily/Flags_SouthernDaily (the quality assessment flags for the Northern and Southern Hemispheres) and SWE_NorthernDaily/SWE_SouthernDaily (the SWE values acquired for the Northern and Southern Hemispheres).

The “file_dict” and “product” variables are used to name the GeoTIFF files created by this Python code.


The output projection information that will be used to georeference the Northern and Southern Hemisphere data are then defined. These projections are NSIDC EASE-Grid North and NSIDC EASE Grid South. 

The spatial resolution of the data is then defined in meters under the variable “spat_res”. For this dataset, the spatial resolution is 25,000 m.

Step 7

A “for loop” is used to loop through each layer in the datafile, determine whether it is in the Northern or Southern hemisphere and define the projection accordingly. For this portion, the upper left coordinates of the data file must be defined in the variables “ullon” (upper left longitude) and “ullat” (upper left latitude).


Please note that the provided values are approximate and considered practical for most applications. These coordinate values should be altered if you desire a more accurate projection for your data use.

Step 8

The remaining portion of the code performs a geographic transformation to georeference the data according the the NSIDC North/South EASE Grid parameters and create GeoTIFF files that are saved to the output folder defined in Step 5.

Simply run the code and check your output directory folder, four GeoTIFFs should now be located within the folder. The files should look like this.

Step 9

One disadvantage of GDAL is it does not define the projection information in a way ArcMap can read, thus when the GeoTIFFs are brought into ArcMap a projection error message will come up. To address this issue you will need to define the projection in ArcMap.

Open your ArcGIS Desktop application. For this tutorial, ArcGIS 10.2 was used.

You will need to search for the tool needed to define the projection of the GeoTIFF files. Click on the ”Geoprocessing” option in the main menu and select “ Search For Tools”.


In the search bar enter “Define Projection” to search for the “Define Projection (Data Management)” tool. Click on the tool name from the list of returned search results to open.

Step 10

Click on the folder icon next to “Input Dataset or Feature Class” field to navigate to the location on your computer where the GeoTIFF files were created and select one. You will see that the geographic information pulled into the window is set as “Unknown”.

Step 11

To define the proper coordinate system select the icon to the right side of the “Coordinate System” field. A “Spatial Reference Properties” window will open. For this dataset, we want to select NSIDC Ease Grid North or South. To navigate to this coordinate system, select “Projected Coordinate Systems” > “Polar” > “NSIDC EASE Grid North” or “NSIDC EASE Grid South”. Then click “OK”.


The name will automatically populate within the “Coordinate System” field. Then click “OK” to run and tool and define the projection.

Step 12

To ensure the correct coordinate system has been defined, double click the GeoTIFF layer name to open the “Layer Properties” window. Select the “Source” tab and scroll down to “Spatial Reference” where you will see that the coordinate system information has been defined and added to the data layer properties. Select “Cancel” to exit out of the window.


Repeat steps 10-12 for the other three GeoTIFF files that were created.

Step 13

You have now created four georeferenced GeoTIFF files containing SWE and quality assessment flags for the Northern and Southern Hemispheres. This data requires additional processing to quality control and remove scales applied to the data values. Please refer to the user guide for additional information on what the created GeoTIFF pixel values found here.


Once the data processing is complete, your data will be ready for analysis.

This code may be additionally altered depending on your data need.

Dataset Name NRT Advanced Microwave Scanning Radiometer 2 (AMSR2) Daily L3 Global Snow Water Equivalent EASE-Grids
Platform Global Change Observations-Water 1 (GCOM-W1)
Instrument Advanced Microwave Radiometer 2 (AMSR2)
Science Parameter Snow water equivalent (SWE)
Format HDF-EOS5
Data Information Data information


Variable Description Dimension Units Scale Factor
Flags_NorthernDaily Daily north flags 2D n/a none
SWE_NorthernDaily Daily north snow water equivalent 2D mm 2.0
Flags_SouthernDaily Daily south flags 2D n/a none
SWE_SouthernDaily Daily south snow water equivalent 2D mm 2.0


Have you used our data? Register for updates