NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.
To learn about what's going on, see About the Archive Site.
Greetings, I have created the following Relationship: (raysId -> (rayBlockageType -> (pbAz, pbRan, pbElevAng, pbMinRayNum, pbMaxRayNum))) by creating a FieldImpl of FlatFields. (I.e., [inner loop] rbTuple[a] = new RealTuple(pbType, pbVals); . . . [outter loop] rayBlockage_ff[b].setSamples(rbTuple, false); . . . [loops are done] raysId_ff.setSamples(rayBlockage_ff, false) ) The stdout of the data look like this:
FieldImpl Type: (raysId -> (rayBlockageType -> (pbAz, pbRan, pbElevAng, pbMinRayNum, pbMaxRayNum))) DomainSet: Integer1DSet: Length = 7200 Range value 0: missing Range value 1: missing Range value 2: missing Range value 3: missing Range value 4: missing Range value 5: missing Range value 6: FlatField Type: (rayBlockageType -> (pbAz, pbRan, pbElevAng, pbMinRayNum, pbMaxRayNum)) DomainSet: Integer1DSet: Length = 4 RangeSet[0]: FloatSet: Dimension = 1 RangeSet[1]: FloatSet: Dimension = 1 RangeSet[2]: FloatSet: Dimension = 1 RangeSet[3]: FloatSet: Dimension = 1 RangeSet[4]: FloatSet: Dimension = 1 (0.4748381972312927, 129091.7109375, 0.1265845000743866, 6.0, 13.0) (0.47140800952911377, 130018.578125, 0.13223420083522797, 6.0, 13.0) (0.4680247902870178, 130945.84375, 0.13688141107559204, 6.0, 13.0) (0.4614015519618988, 132799.640625, 0.13808868825435638, 6.0, 13.0)
. . .I then save raysId_ff to a netCDF file using the save() method in Plain, but this does something very odd to the data. When I open the data using Plain open() the data are returned like this:
FlatField ((rayBlockageType_ndx, raysId) -> (pbAz, pbRan, pbElevAng, pbMinRayNum, pbMaxRayNum)) (missing, missing, missing, missing, missing) (missing, missing, missing, missing, missing) (missing, missing, missing, missing, missing) (missing, missing, missing, missing, missing) (missing, missing, missing, missing, missing) (missing, missing, missing, missing, missing) (0.4748381972312927, 129091.7109375, 0.1265845000743866, 6.0, 13.0)
I dumped the netCDF file and noticed that for each "Range Value" listed above, it only saved the forst line in "RangeSet[4]". I.e., for Range Value 6 (above), only
(0.4748381972312927, 129091.7109375, 0.1265845000743866, 6.0, 13.0) was saved, while the rest: (0.47140800952911377, 130018.578125, 0.13223420083522797, 6.0, 13.0) (0.4680247902870178, 130945.84375, 0.13688141107559204, 6.0, 13.0) (0.4614015519618988, 132799.640625, 0.13808868825435638, 6.0, 13.0)was not saved to the netCDF file. Do I have to specify the format to be saved in the netCDF file so that all the data are saved? I don't understand why the rest of the data are not beig saved, except that the headdder of the netCDF file (dumped) looks like this:
netcdf experimentalDump { dimensions: rayBlockageType_ndx = 1 ; raysId = 7200 ; variables: float rayBlockageType(rayBlockageType_ndx) ; double pbAz(raysId, rayBlockageType_ndx) ; pbAz:_FillValue = 9.96920996838687e+36 ; pbAz:units = "deg" ; double pbRan(raysId, rayBlockageType_ndx) ; pbRan:_FillValue = 9.96920996838687e+36 ; pbRan:units = "m" ; double pbElevAng(raysId, rayBlockageType_ndx) ; pbElevAng:_FillValue = 9.96920996838687e+36 ; pbElevAng:units = "deg" ; double pbMinRayNum(raysId, rayBlockageType_ndx) ; pbMinRayNum:_FillValue = 9.96920996838687e+36 ; double pbMaxRayNum(raysId, rayBlockageType_ndx) ; pbMaxRayNum:_FillValue = 9.96920996838687e+36 ; data: rayBlockageType = 0 ; pbAz _, _, _, _, _, _, 0.474838197231293,
. . .If this is unclear, I can clean up my code and place it so that others can test it out.
Thanks! -kevin. -- +------------------------------------------------------------+ Kevin L. Manross [KD5MYD] <>< (405)-366-0557 CIMMS Research Associate kevin.manross@xxxxxxxx [NSSL-WRDD/SWATN] http://www.cimms.ou.edu/~kmanross "My opinions are my own and not representative of CIMMS, NSSL, NOAA or any affiliates" +------------------------------------------------------------+
visad
archives: