Creating a Python program to automatically download the ionex file given any date as input to the program.

Use this Forum to find information on, or ask a question about, NASA Earth Science data.
Post Reply
kaustavchoubey
Posts: 1
Joined: Wed Sep 21, 2022 10:36 am America/New_York
Answers: 0

Creating a Python program to automatically download the ionex file given any date as input to the program.

by kaustavchoubey » Wed Sep 21, 2022 11:03 am America/New_York

I am working on a research project related to ionosphere. I have created a program that downloads the ionex file for a date if I give that date as an input to the program. The issue is that ionex files are normally about 200 kb in zipped form and this program is downloading files of just about 12 kb. So, it is only partially downloading the file. Without this program, I won't be able to proceed in my research project. Please could you help me?

The link to the program is here:

https://colab.research.google.com/drive/1PSVviw4dmleC544vCMdZXb5eWWbwr0_K?usp=sharing

Tags:

CDDIS_support_Lori
User Services
User Services
Posts: 78
Joined: Mon Sep 30, 2019 11:17 am America/New_York
Answers: 0

Re: Creating a Python program to automatically download the ionex file given any date as input to the program.

by CDDIS_support_Lori » Wed Sep 28, 2022 12:00 pm America/New_York

The most common reason for this is that you are not properly passing your credentials to Earthdata login. If you do not pass your credentials properly you are automatically redirected to the Earthdata Login web page. Since you are making an HTTPS request, the server is assuming you are using a web browser and returns the login page. This normally occurs when your .netrc file is missing or in the wrong place, or you have the wrong credentials in your .netrc file. You need to create a .netrc file with your credentials. You can read the instructions for this here: https://cddis.nasa.gov/Data_and_Derived_Products/CreateNetrcFile.html

Best regards,

The CDDIS Team

Post Reply