How to regrid the spatial data in netcdf format directly without reading it
Mostrar comentarios más antiguos
I am dealing with a large size data (aprox 3 Gb) in netcdf data with 0.004 degree resolution, trying to regrid it to 0.05 degree resolution. The problem I am facing here is the size of data (Out of memory(10902x6818x846)).
Is there any way to regrid (0.004 to 0.05) this data directly without reading (ncread) in matlab and any other to deal it within matlab?
I have gone through interp3 and get idea to execute it but the size of data is curtailing me to do so.
Thank you in advance for any kind of help.
3 comentarios
Walter Roberson
el 12 de En. de 2019
Is it a 3D regriding you need to do, or can you regrid slice by slice?
Which NetCDF format are the files in? In particular if they are NetCDF 3 or below then it looks like direct binary access into the file is hypothetically possible, whereas NetCDF 4 and above use HDF5 underneath and have the possibility of compression making it more difficult to extract arbitrary data without using the routines.
Shakir Hussain
el 12 de En. de 2019
Walter Roberson
el 12 de En. de 2019
One thing I have noticed about precipation data is that it is not uncommon for there to be a bunch of missing data. Data marked as missing in netcdf files will typically show up as NaN at the MATLAB level (no matter how it is stored in netcdf.) Do you have the possibility of nan in what you read in? If you do then you need to take more care in the regridding process, as NaN often "poison" the calculations.
The default for interp2 is bilinear interpolation: the new values for any location that is not at an exact vertex is determined by interpolation from the left, right, up, down neighbours of the requested location. If one of those is NaN, then the result will be NaN. How would you like that situation handled?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre NetCDF en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!