Page 2 of 2

Re: Python script to download VIIRS data doesn't work after Jan 2023

Posted: Fri Mar 10, 2023 11:33 am America/New_York
by tahersima
Thanks! I need to download thousands of URLs, otherwise I could just download a single file from the browser!

I am probably missing something very basic. But I don't understand how could I provide a directory tree in JSON or CSV format when the -s argument requires me to provide a URL?

I tried a couple of things:
- providing URL from the earthdata download status page: https://search.earthdata.nasa.gov/downloads/0318464386. when I do this, the code gives me a new error: "filesize = int(f['size'])"
- providing a csv file containing hundreds of URLs from my local drive. When I do that, I get another error: "Failed to make request: unknown url type: c" telling me it expects a URL and not a CSV file.

I don't know how to provide a CSV or JSON file using a URL when the CSV file is stored locally.

Re: Python script to download VIIRS data doesn't work after Jan 2023

Posted: Mon Mar 13, 2023 11:01 am America/New_York
by LAADS_UserServices_M
The information related to Python script, curl, and wget sent was for data download directly from LAADS archive and for orders placed on ladsweb. These scripts may not work with earthdata orders. So, you either use the download script provided on Earthdata "Download Status" page (e.g., on https://search.earthdata.nasa.gov/downloads/0318464386 page) or use LAADS scripts directly with ladsweb/archive. If you have a question about the script provided by Earthdata search please generate a new question and tag it such (and to avoid confusion please don't add LAADS in the tags).
As an alternative, you may also explore LAADS Web Service API-V2 to automate data search and download. You can find information about this option at:
https://ladsweb.modaps.eosdis.nasa.gov/tools-and-services/#api-v2
and a tuorial at:
https://ladsweb.modaps.eosdis.nasa.gov/learn#tutorials

We apologize for all the confusion.