GET_2DFLD - error while reading variable: Uwind at TIME index = 12
It seems that the model did't read the grid successfully, since the the minimum and maximum of Lon and Lat are all 0. I did check very carefully to make sure I have gave the right directory of the grid. And there was no other errors indicating the grid was not right.
And I have tried to gave the Uwind data(Uwind.nc) both before interpolation and after interpolation, both are the similar errors.
I will appreciate very much if someone can give me some suggestions.
I thought I have got the the reason. It was indeed the problem of my grid. I got the grid using easygrid, in which grid type is not spherical. So, I changed nc{'sperical'}(:)='F' to nc{'spherical'}(:)='T', and add the parameter of 'angle' in the grid. Then, the problem above is gone.
Hi Justina:
I have a similar problem.... Could you tell me where do you edited c{'sperical'}(:)='F' to nc{'spherical'}(:)='T' ? please, in the seagrid window or in a roms' script?
-
Thanks in advance
-
Mar.Mo.
This is the sort of thing I would do in a scripting language such as Python or Matlab or NCL or Ferret. It's good to develop some skills like editing NetCDF files in one of them. Ask around your friends to see which one they can help you get started in or look at online examples.
Dear Kate, thanks for you replay
My NetCDF grid file have the next description:
Variables:
spherical
Size: 1x1
Dimensions:
Datatype: int32
Attributes:
long_name ='grid type logical switćh'
flag_values=[0 1]
flag_meanings='Cartesian spherical'
Do I neet to change the flag_meanings 'Cartesian spherical' to only 'spherical' ? in the NetCDF file
-
Thanks in advance.
Mar.Mo.
Once upon a time, spherical was a logical flag, true or false. Somebody's Netcdf interface worked better if spherical is an integer instead, so it was changed. The attributes are telling you that valid values are 0 and 1, with meanings Cartesian and spherical, respectively. You are showing us the metadata for the spherical variable, but not its value. You need to change the value to 1. If you only had to change the metadata, I would use the NCO package. For changing values, I turn to Python and the Python NetCDF4 package.
Hi!
So many thanks for your's answers, were so usefull to me.
My spherical value is 1, the problem was resolved when I did my grd.in file with a different seagrid2roms.m, which changed 'spherical=1' for 'spherical=T'.
-
Mar.Mo.