Download data

In this section, you will learn how to order Landsat data from the USGS, including how to search only for the area we are interested in.

You will attempt to find two clear scenes (cloud-free or nearly so) for your area of interest.

You will then learn how to download the datasets.

Finally, we present one manual and one automated method for scaling the data, subsetting and producing a mask.

This is a skill you will need to complete the assessed coursework.

Once you have this skill, you can start collecting the datasets for the practical.

You do not need to use the 'automated' subsetting method: you can do everything manually if you wish.

Downloading and visualisation tools

The first task is to download the data that you will need.

There are several tools available to you for browsing and ordering Landsat data. See the USGS for a full description of the data products and where to order them.

You will most often be interested in surface reflectance products. These can be ordered through the USGS Earth Resources Observation and Science (EROS) Center Science Processing Architecture (ESPA) On Demand Interface.

The first time you visit the ordering service, you will need to register for an account. Make sure you remember the usename and password you used for registration!

Once at the USGS Earth Resources Observation and Science (EROS) Center Science Processing Architecture (ESPA) On Demand Interface site, make yourself aware of the information on surface reflectance.

Select Landsat Scenes

To select a particular landsat scene, go to the Earth Explorer site.

Enter the place you are interested in, in the Search Criteria (e.g. try: London, England) or select an area on the graphic.

Under Data Sets, look in Landsat Archive -> Pre-collection and check all of the boxes that have 'surface reflectance'. This will be for different sensors in the Landsat series (LS4-5, LS-7, LS-8).

You may wish to set a cloud cover limitation (e.g. 10%) under Additional Criteria.

Click on 'Results' and look at a few of the images. In particular, you should look at which PATH and ROW is appropriate for the area you want data for. This could, for example be

    Path 201
    Row 24


Now, you can go back to the Search Criteria and enter just the path/row that you want, and/or just go through and add the files you want to download to the basket.

You can the view the basket, and submit the order.

You should first try this with a small number of datasets, but it is quite straightforward to order many scenes if you need them.

If the order has worked, you will receive an email and also a notification when the data are ready for download.

You can also check this through the API, e.g. by clicking https://espa.cr.usgs.gov/api/v0/list-orders and entering your username and password.

Alternatively, for a particular order (in this case, p.lewis@ucl.ac.uk-0101701110213, with MYUSERNAME:MYPASSWORD set appropriately), use e.g.:

curl --user MYUSERNAME:MYPASSWORD https://espa.cr.usgs.gov/api/v0/order/p.lewis@ucl.ac.uk-0101701110213

Once you get confirmation that the order is ready (this can, at times, take days but is usually less), you can then download the dataset.

Download ordered data

You can simply download the data by following the links in the email you receive.

Alternatively, there are various tools you can use for bulk download.

One example is espa-bulk-downloader, which is a python script. You use this, e.g.:

    download_espa_order.py -e p.lewis@ucl.ac.uk -d ~/Downloads -u p.lewis@ucl.ac.uk -p MYPASSWORD -o ALL

Fixing Landsat 7 SLC issues

If you make use of Landsat 7 data (after slc failure in 2003) you may wish to perform a 'gap filling' on the dataset prior to use.

There are many such algorithms. One you can use quite easily is mentioned here.

To use this, download the file Landsat Gapfill IDL Model and copy it to your 'extensions' directory. On a unix machine, this will involve e.g.:

    cp ~/Downloads/landsat_gapfill.sav ~/.idl/envi/extensions5_2


Then, you should find the model available to you the next time you run envi, under the extensions menu.

You may need to run this file seperately for each waveband.

Easier ordering

If you have a particular scene you want to order, e.g. LE72010242008129ASN00

    curl --user p.lewis@ucl.ac.uk:ST6-kyH-TBZ-ATy -d '{"etm7": {
                                                "inputs": ["LE72010242008129ASN00"], 
                                                "products": ["sr","cloud"]
                                             }, 
                                 "format": "envi", 
                                 "resize": {
                                            "pixel_size": 30, 
                                            "pixel_size_units": "meters"
                                            }, 
                                 "resampling_method": "nn", 
                                 "plot_statistics": true, 
                                 "projection": {
                                                "utm": {
                                                        "zone": 30,
                                                        "zone_ns": "north"
                                                        }
                                                },
                                 "note": "my first order..."
                                 }' https://espa.cr.usgs.gov/api/v0/order



One useful feature of this way of ordering is that you can specify the file format. In this case, we specify envi format, which saves us having to mess around with file formats once we download the data.

3.5 Download Scenes

You will be sent an email from the USGS.

You must keep this email to show evidence that you have ordered the data.

The email will give you a web address that will look something like http://espa.cr.usgs.gov/ordering/order-status/p.lewis@ucl.ac.uk-01112017-113611-005.

If you have recent or active orders, this web page should show you the status for each file (wait until it says 'complete').

Then, you can download the file (using the Download link).

You must keep a record of the download links to show evidence that you have ordered the data, e.g.:

http://espa.cr.usgs.gov/orders/f.bloggs@nasa.gov-0101502242983/LE71220442000306-SC20150224104838.tar.gz

Save all of the download links in a file toi include in your report.

The filename will be something like:

LE71220441999255-SC20150217105511.tar.gz

There is no need to 'unzip' or 'untar' the file: just download it for the moment.

Make sure you remember which directory you have downloaded the data to.

You should probably download the datasets to you DATA disk, or you might run out of quota, or at least move the files to the DATA disk soon after.

As the files are quite large, it may take some minutes to download each scene.