All Questions
54
questions
2
votes
1
answer
36
views
Create .nc file from multiple tif files : metadata time
I'm trying to create a single .nc file with 3 dimensions : x,y and time. In order to do so I have multiple tif files named by their date : 2013-04-24_Turb.tif for the 24-04-2013. I would like to do ...
0
votes
0
answers
101
views
Performance difference between xarray open_mfdataset and open_dataset
I'm dealing with CMIP6 Scenariomip data, I have eight ESMs precipitation grid that each one is composed by multiple netcdf files. There is one ESMs's netcdf files are seperately reserved every decade, ...
1
vote
1
answer
132
views
While exporting the rasters using rioxarray, nodata value is undefined after the mask
I have used xarray to open the netcdf file, and using rioxarray exported the raster as a .tif file. However, the exported raster doesn't have definition for nodata value, and hence, the GIS software ...
0
votes
0
answers
61
views
How can I extract the array indices from a xarray.rio.clip operation?
I have a line of code that clips a Dataset from a larger xarray.core.dataset.Dataset.
clipped = ds.rio.clip([user_polygon], crs=4326, all_touched=True)
I need to process many of these large datasets (...
3
votes
1
answer
411
views
How to write CRS info to NetCDF in a way QGIS can read? (Python/Xarray)
I have a NetCDF file I have subset by geometry and time, and now I need to save it as a new NetCDF file. The original file does not have the CRS set, thus I am setting it in this one. The problem is ...
0
votes
1
answer
66
views
QGIS crashes with "bad_alloc" when processing NetCDF file using xarray
I need to merge multiple NetCDF files in a QGIS plugin I am developing. I'm using xarray to do so, however, QGIS crashes with the error "Critical: Caught unhandled std::exception: std::bad_alloc&...
0
votes
0
answers
44
views
Change dtype of coordinates NetCDF
I was wondering how to change the dtype from float32 to float64 of coordinates.
I can run the following code in the terminal
ncap2 -s 'lat=double(lat); lon=double(lon)' infile.nc outfile.nc
How ever ...
0
votes
1
answer
603
views
Extract nearest values from NetCDF file in Python
I have a NetCDF database (link to file) obtained from Copernicus Climate Data of ~43k unevenly spaced values around the world. Instead of being indexed using (lat, lon) it uses a sequence of 'stations'...
1
vote
0
answers
177
views
Saving extracted array into new NetCDF file
I have a NetCDF file which looks like this:
<xarray.Dataset>
Dimensions: (time: 180, d2: 2, lat: 180, lon: 360)
Coordinates:
* time (time) object 2000-01-15 12:00:00 ... 2014-12-15 12:...
1
vote
1
answer
1k
views
Interpolate irregularly sampled data to a regular grid
I'm using .nc files with spatially referenced timeseries data in xarray, i.e. inherently 3-dimensional data (lat, lon, time). My issue is, that the dataset's coordinates lat and lon are merged to a ...
1
vote
0
answers
158
views
Convert the netcdf file to geotiff with chosen coordinate system
I have a nc file retrieved from the following link https://www.globsnow.info/swe/nrt/2020/data/GlobSnow_SWE_L3A_20200110_v.1.0.nc.gz. I am trying to convert this file to geotiff in wgs 1984 coordinate ...
0
votes
1
answer
406
views
Error reading variables from NetCDF file with Xarray when there are multiple variable layers
I get an error reading variables from NetCDF file with Xarray when there are multiple variable layers
Data:
The netCDF file that I have has multiple layers:
/Geophysical_Data/...
2
votes
2
answers
1k
views
Is it possible to change a coordinate in an netCDF loaded with xarray?
I have a netCDF which is loaded in xarray with a dimension named bands (it was originally an import via rioxarray of ENVI data), but actually, I want to be able to parse the data by time. I have tried ...
0
votes
1
answer
850
views
Convert a multiband GeoTIFF to a timeseries NetCDF file in xarray
I am trying to create a time series object from extracted climate data (NEX-GDDP) using the Google Earth Engine (GEE). The data is daily meteorological data, and in the attached file, the data for ...
0
votes
1
answer
109
views
GeoServer Java error when adding layer from NetCDF based store
Using xarray I have subsetted surface current data from the https://resources.marine.coperncus.eu OPeNDAP server. I save the subset as a NetCDF4 file. I am able to add the NetCDF file as a store in ...