Skip to content

How can I use S3 links when earthaccess does not detect that I'm in-region (in us-west-2)? #845

Answered by chuckwondo
chuckwondo asked this question in Q&A
Discussion options

You must be logged in to vote

A very simple way to get this to work is to add the following line after the call to earthaccess.login() (suggested by David Giles):

earthaccess.__store__.in_region = True

However, use the approach above at your own risk. I recommend against this approach because __store__ is not part of the library's "public" API. Thus, it is subject to change without notice, and there is no promise of any sort of backward compatibility, which is generally the case for the non-public API of any library.

Instead, I recommend the following approach:

import earthaccess
import xarray as xr

earthaccess.login()

results = earthaccess.search_data(
    short_name='VNP03IMG',
    bounding_box=(-125, 31, -102, 49.2

Replies: 1 comment 8 replies

Comment options

You must be logged in to vote
8 replies
@chuckwondo
Comment options

@chuckwondo
Comment options

@itcarroll
Comment options

@chuckwondo
Comment options

@chuckwondo
Comment options

Answer selected by chuckwondo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants