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'm using NCL function wrf_wps_write_int to convert NetCDF variables into WPS intermediate format. However, the function does not write the level correctly. No matter what value is provided, the function writes level=0 into the file.
Here is a sample code,
f = addfile("ta_6hrPlevPt_MPI-ESM1-2-LR_historical_r1i1p1f1_gn_201001010600-201501010000.nc", "r")
ta = f->ta(0:ntime-1,:,:,:)
lat := f->lat
lon := f->lon
plev := f->plev
nlev = dimsizes(plev)
nlats = dimsizes(lat)
DONE WRITING TT (level= 0.) for time 2010-01-01_06 to IM Format
Variable: opt
Type: logical
Total Size: 4 bytes
1 values
Number of Dimensions: 1
Dimensions and sizes: [1]
Coordinates:
Number Of Attributes: 11
level : 100000
is_wind_earth_relative : False
nlats : 96
deltalat : 1.849637559339129
deltalon : 1.875
startlat : -88.57216851400727
startlon : 0
startloc : SWCORNER
map_source : MPI-ESM1-2-LR
date : 2010-01-01_06
projection : 4
I have tested the function on different HPCs from NCAR and NERSC with NCL installed (V6.6.2) and the problem persists. I'm not sure whether there's a bug in my script or in the source code. May I get some attention to it?
The text was updated successfully, but these errors were encountered:
It turned out to be a mismatch of the required data type for opt@level and plev from the dataset. When convert plev to float or integer, the function works as supposed.
Hello,
I'm using NCL function wrf_wps_write_int to convert NetCDF variables into WPS intermediate format. However, the function does not write the level correctly. No matter what value is provided, the function writes level=0 into the file.
Here is a sample code,
f = addfile("ta_6hrPlevPt_MPI-ESM1-2-LR_historical_r1i1p1f1_gn_201001010600-201501010000.nc", "r")
ta = f->ta(0:ntime-1,:,:,:)
lat := f->lat
lon := f->lon
plev := f->plev
nlev = dimsizes(plev)
nlats = dimsizes(lat)
The output messages are as follows,
I have tested the function on different HPCs from NCAR and NERSC with NCL installed (V6.6.2) and the problem persists. I'm not sure whether there's a bug in my script or in the source code. May I get some attention to it?
The text was updated successfully, but these errors were encountered: