You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a time series of Sentinel-2 images, where each band is stored in its own file. I'd like to combine bands and time to create a multidimensional array, and store it as a single HDF5/NetCDF file for convenience.
I managed to use open_mfdataset to create this tensor, however the files with a lower resolution do not get interpolated, but rather "stretched" with holes filled by NaNs:
However some of the bands have NaNs due to the stretch.
I tried to interpolate the lower resolution bands in the preprocess function: the resulting xarray Dataset is in fact now 264x264 (which is my desired shape), however the final output of the open_mfdataset now becomes way bigger than expected:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I have a time series of Sentinel-2 images, where each band is stored in its own file. I'd like to combine bands and time to create a multidimensional array, and store it as a single HDF5/NetCDF file for convenience.
I managed to use
open_mfdataset
to create this tensor, however the files with a lower resolution do not get interpolated, but rather "stretched" with holes filled by NaNs:gives the following Dataset:
However some of the bands have NaNs due to the stretch.
I tried to interpolate the lower resolution bands in the
preprocess
function: the resulting xarray Dataset is in fact now 264x264 (which is my desired shape), however the final output of theopen_mfdataset
now becomes way bigger than expected:Is it possible to obtain a Dataset with shape
(264, 264)
, where the lower resolution bands are interpolated to the desired dimension?Thanks!
Beta Was this translation helpful? Give feedback.
All reactions