I have a set of code that builds an HLS data cube over a given location and time-interval, then runs further processing. As part of that, this data cube needs to be loaded into memory with persist().
The code works well in most scenarios. However, I have found that one particular tif is unable to be accessed, triggering an error and preventing the HLS data cube from being loaded into memory.
The relevant portions of the error:
CPLE_OpenFailedError: '/vsicurl/https://data.lpdaac.earthdatacloud.nasa.gov/lp-prod-protected/HLSL30.020/HLS.L30.T10UDU.2014082T190147.v2.0/HLS.L30.T10UDU.2014082T190147.v2.0.B06.tif' does not exist in the file system, and is not recognized as a supported dataset name.
RuntimeError: Error opening 'https://data.lpdaac.earthdatacloud.nasa.gov/lp-prod-protected/HLSL30.020/HLS.L30.T10UDU.2014082T190147.v2.0/HLS.L30.T10UDU.2014082T190147.v2.0.B06.tif': RasterioIOError("'/vsicurl/https://data.lpdaac.earthdatacloud.nasa.gov/lp-prod-protected/HLSL30.020/HLS.L30.T10UDU.2014082T190147.v2.0/HLS.L30.T10UDU.2014082T190147.v2.0.B06.tif' does not exist in the file system, and is not recognized as a supported dataset name.")
Note that it is always the same tif link that is provided by the error, and retrying the function triggers the same error.
Any help would be appreciated!
- User Services
- Posts: 209
- Joined: Mon Sep 30, 2019 10:00 am America/New_York
- Has thanked: 9 times
Sign up for the Landsat listserv to receive the most up to date information about Landsat data: https://public.govdelivery.com/accounts/USDOIGS/subscriber/new#tab1.
- User Services
- Posts: 248
- Joined: Mon Sep 30, 2019 12:39 pm America/New_York
- Has thanked: 8 times
If you are unable to load EarthData assets from https URLs via vsicurl and rasterio in Python, there are 3 common solutions:
1. Ensure you have a properly configured .netrc file. Instructions can be found [here|https://github.com/nasa/LPDAAC-Data-Resources/blob/main/notebooks/Earthdata_Authentication__Create_netrc_file.ipynb].
2.Ensure that you have set the necessary gdal configurations to access data using vsicurl. The below code can be used to set these:
3. Sometimes cached information can cause an issue, to resolve this, try restarting your Python Kernel.