[ncl-talk] Radar PPI dimension size problem with Conform

Mary Haley haley at ucar.edu
Thu Apr 20 17:47:06 MDT 2017


Hi all,

Just an FYI. The NetCDF file for radar_2.ncl looks like this for "angles"
and "dbz":

Variable: angles
Type: float
Total Size: 17372 bytes
            4343 values
Number of Dimensions: 1
Dimensions and sizes:   [time | 4343]
Coordinates:
            time: [   0.. 434]
Number Of Attributes: 2
  standard_name :       beam_azimuth_angle
  units :       degrees

Variable: dbz
Type: float
Total Size: 17302512 bytes
            4325628 values
Number of Dimensions: 2
Dimensions and sizes:   [time | 4343] x [range | 996]
Coordinates:
            time: [   0.. 434]
            range: [150..149400]
Number Of Attributes: 10
  long_name :   Computed Horizontal Co-polar Reflectivity
  standard_name :       equivalent_reflectivity_factor
  units :       dBZ
  threshold_field_name :
  threshold_value :        0
  sampling_ratio :         1
  grid_mapping :        grid_mapping
  coordinates : time range
  _FillValue :  -32768

You can see that the size of angles is the same as the leftmost dimension
of dbz.

I'm not sure what "REF" and "angles" are referring to on your file. They
don't appear to be related to each other, since their dimension sizes are
not multiples of each other.

Is it possible you need to use a different variable on the file?

--Mary


On Thu, Apr 20, 2017 at 1:27 PM, Ryan Connelly <rconne01 at gmail.com> wrote:

> Hi Barry,
>
> No idea about the format, though it's possible since DBZ is not a variable
> in the netCDF (it's REF now).  I use radx to convert the Level II files
> from their native format to CfRadial netCDF's, nothing involving the WCT.
>
> Thanks,
> Ryan
>
> On Wed, Apr 19, 2017 at 10:45 PM, Barry Lynn <barry.h.lynn at gmail.com>
> wrote:
>
>> Hi Ryan:
>>
>> Is it possible that the format of the radar data has changed?
>>
>> I had to write several Fortran programs to read the radar data from
>> different years (as processed by the NOAA Weather and Climate Tool).  I
>> write out the data and then map it objectively using a wrf output program
>> as the gridded background.
>>
>> I can send you these programs if you like.
>>
>> Barry
>>
>> On Wed, Apr 19, 2017 at 11:28 PM, Ryan Connelly <rconne01 at gmail.com>
>> wrote:
>>
>>> Hi,
>>>
>>> I'm looking at the example here: http://www.ncl.ucar.edu/Applic
>>> ations/Scripts/radar_2.ncl but encountering the error:
>>>
>>> fatal:conform: the dimensions sizes of the second argument do not match
>>> those indicated by the third argument
>>>
>>>
>>> Here is the code up to that point:
>>>
>>> begin
>>>
>>>   fils = systemfunc ("csh -c 'cd " + diri + " ; ls *.nc'")
>>>   do j = 0,dimsizes(fils)-1,1
>>>        fili = fils(j)    ;+".nc"
>>>        rf    = addfile(diri+fili,"r")
>>> ;       print(getfilevarnames(rf))
>>>        rd    = rf->REF ;short2flt(rf->REF)
>>>        dsizes = dimsizes(rd)
>>>        angles = rf->azimuth
>>>        angles(0:63) = angles(0:63)-360  ; fix to make angles monotonic
>>>        DEGTORAD = 0.017453292519943
>>>        xcenter  = 0.0
>>>        ycenter  = 0.0
>>>        radius   = 960 * 0.25 ; this is radius in kilometers
>>>
>>> ; Create 2D coordinate arrays.
>>> ;
>>>        printVarSummary(rd(0))
>>>        printVarSummary(angles)
>>>
>>>        inc      = radius / (dsizes(0) - 1)
>>>        x        = inc * ispan(0,dsizes(0)-1,1)
>>>        angles2d = conform(rd,angles,0)
>>>        x2d      = conform(rd,x,1)
>>>        xarr     =  xcenter + x2d  * cos(DEGTORAD * angles2d)
>>>        yarr     =  ycenter + x2d  * sin(DEGTORAD * angles2d)
>>>
>>>
>>> It seems that there's a mismatch between rd(0) and angles?  rd is
>>> one-dimensional with 6701760 points, and angles is also one-dimensional,
>>> with 5400 points.
>>>
>>> Thanks,
>>> Ryan
>>>
>>> --
>>> Ryan Connelly
>>> M.S. Student in Atmospheric Sciences, Stony Brook University
>>> B.S. in Meteorology with Minors in Mathematics and GIS, Valparaiso
>>> University
>>> rconne01 at gmail.com
>>> ryan.connelly at stonybrook.edu
>>>
>>> _______________________________________________
>>> ncl-talk mailing list
>>> ncl-talk at ucar.edu
>>> List instructions, subscriber options, unsubscribe:
>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>
>>>
>>
>>
>> --
>> Barry H. Lynn, Ph.D
>> Senior Lecturer,
>> The Institute of the Earth Science,
>> The Hebrew University of Jerusalem,
>> Givat Ram, Jerusalem 91904, Israel
>> Tel: 972 547 231 170
>> Fax: (972)-25662581
>>
>> C.E.O, Weather It Is, LTD
>> Weather and Climate Focus
>> http://weather-it-is.com
>> Jerusalem, Israel
>> Local: 02 930 9525
>> Cell: 054 7 231 170
>> Int-IS: x972 2 930 9525
>> US 914 432 3108 <(914)%20432-3108>
>>
>
>
>
> --
> Ryan Connelly
> M.S. Student in Atmospheric Sciences, Stony Brook University
> B.S. in Meteorology with Minors in Mathematics and GIS, Valparaiso
> University
> rconne01 at gmail.com
> ryan.connelly at stonybrook.edu
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170420/8a1ec3ed/attachment.html 


More information about the ncl-talk mailing list