Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem of Downloading Landsat8 Collection2 Product #72

Closed
xiaojiujiu999 opened this issue Mar 9, 2022 · 1 comment
Closed

Problem of Downloading Landsat8 Collection2 Product #72

xiaojiujiu999 opened this issue Mar 9, 2022 · 1 comment

Comments

@xiaojiujiu999
Copy link

xiaojiujiu999 commented Mar 9, 2022

I download Landsat8 Collection2 Data, bue get a Collection1 Data
The downloading file doesn't match the local file
I don't know why it happens......

图片

The function of downloading is paste here as following:

def Download_from_Landsatexplore(dataset,scene_list):
    if len(scene_list) > 0:
        for scene in scene_list:
            if dataset.lower() == "landsat_8_c1":
                output_dir = r'G:\landsat_download\landsat_8_c1' 
            elif dataset.lower() == "landsat_ot_c2_l1":
                output_dir = r'G:\landsat_download\landsat_ot_c2_l1' 
            elif dataset.lower() == "landsat_ot_c2_l2":
                output_dir = r'G:\landsat_download\landsat_ot_c2_l2' 
            else:
                output_dir = r'G:\landsat_download\other'
            
            if not os.path.isdir(output_dir):
                os.mkdir(output_dir)
            
            output_dir_demon = output_dir+'\\'+str(scene['acquisition_date'].year)
            if not os.path.isdir(output_dir_demon):
                os.mkdir(output_dir_demon)
            ee = EarthExplorer(username, password)
            print("Downloading: "+scene['display_id'])
            ee.download(identifier=scene['entity_id'], output_dir=output_dir_demon)
@xiaojiujiu999
Copy link
Author

#45 has solved the problem!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant