[Thread Prev][Thread Next][Index]

Re: [las_users] Lat/Lon problems



Hello again everyone,

For an update on my problem, I was able to display  the variables which only depend on lat and lon using the documentation here: http://ferret.pmel.noaa.gov/LAS/documentation/installer-documentation/adding-curvilinear-data/. Thank you Roland for your guidance on that.

However, I am faced with a new problem. The remaining variables depend on lat, lon, and a time dimension as well as you can see in the sample variable definition below:

        float e(time, yaxis, xaxis) ;
                e:long_name = "water surface elevation" ;
                e:units = "meter" ;
                e:figure = "scalar" ;

The graph can be displayed in Ferret using the commands:

        shade e[l=1]

up to the maximum time which is:

        shade e[1:84]

Below is the definition of 'time' and of 'e' in the netCDF file:

        dimensions:
                time = UNLIMITED ; //(84 currently)

        variables:
                double time(time) ;
                        time:long_name = "coordinate variables of time" ;
                        time:units = "second since 2008-01-22" ;
                        time:figure = "na" ;
                float e(time, yaxis, xaxis) ;
                        e:long_name = "water surface elevation" ;
                        e:units = "meter" ;
                        e:figure = "scalar" ;
                        e:_FillValue = 9.96921e+36f ;
   
                data:
                         time = 86400, 87300, 88200, 89100, 90000, 90900, 91800, 92700, 93600, 94500 ;

Lastly, below is my axes definition in the XML file:

        <axes>
          <lon-x-id-01ced4ab23 type="x" units="degrees_east">
            <arange start="102.8096" size="1320" step="1.75" />
          </lon-x-id-01ced4ab23>
          <lat-y-id-01ced4ab23 type="y" units="degrees_north">
            <arange start="0.1909" size="1482" step="1.2" />
          </lat-y-id-01ced4ab23>
          <time-t-id-01ced4ab23 type="t" units="minute">
            <arange start="2008-01-23 00:00:00" size="84" step="15" />
          </time-t-id-01ced4ab23>
        </axes>

I have attached a screenshot of the error being returned when the plot is trying to be loaded. Your kind help on the matter is greatly appreciated!
--
Regards,
Anton Yoel Buenavista

-------- Original Message  --------
Subject: Re: [las_users] Lat/Lon problems
From: Roland Schweitzer <Roland.Schweitzer@xxxxxxxx>
To: Buenavista Anton Yoel Dioquino <tmsbayd@xxxxxxxxxx>
Cc: Laurent Demagistri <laurent.demagistri@xxxxxxxxxx>, "las_users@xxxxxxxx" <oar.pmel.las_users@xxxxxxxx>
Date: Friday, 19 February, 2010 10:55:37 PM
Hello,

It looks like your data uses 2D lat and lon variables.  LAS can handle such data, but it requires some additional metadata in the configuration.  You can read about how it's done here: http://ferret.pmel.noaa.gov/LAS/documentation/installer-documentation/adding-curvilinear-data/.

The latest version of addXML can produce configuration automatically for many data files with 2D coordinates.  You can get the latest version (1.7.1) here: ftp://ftp.pmel.noaa.gov/pub/las/addXML/addxml.1.7.1.tar.gz.

Try it and if it does not work, if you can send me a small example netCDF file or an OPeNDAP URL for an example I'll run it in the debugger to see if I can make it work.

Roland

Anton Yoel Buenavista wrote:
Dear Laurent,

Thank you for your reply. I have just talked with my fellow researchers and have been discussing the issues regarding our NetCDF files. I have come to know some other details, hence my next set of question.

Is there a way for LAS to display non-geographic data? (i.e. data that is not based on lon,lat coordinates but is based on arbitrary x,y coordinates.)

We can plot the data using Ferret. (See attached plot.) But we're wondering how to get the same plot from LAS. The plot does show a map, but its North is not along the Y axis but about 45degrees off, as you can see in the plot.

Any pointers and advice would be welcome.

Regards,
Anton Yoel Buenavista


Laurent Demagistri wrote:
Dear Anton,
I am new to LAS too and had to face that problem too.
Here is part of my data conversion script in IDL.
In my memory, I had to add the "..'positive', 'down'.." attribute to the
NetCDF file "Z"-dimension
for addXML to be able to recognize it the right way.

....
zid = NCDF_VARDEF(id, 'zlev', [zlev_id], /FLOAT)
NCDF_ATTPUT, id, zid, 'units', 'meters'
NCDF_ATTPUT, id, zid, 'long_name', 'Depth'
NCDF_ATTPUT, id, zid, *'positive', 'down'*
....

Hope this helps.
Regards.

Laurent.


Anton Yoel Buenavista a écrit , Le 18.02.2010 09:26:
  
Hello everyone,

I have just recently installed LAS v7.0.3. Everything works perfectly
and the sample COADS NetCDF files provided displays perfectly as well.
The NetCDF files provided by my colleagues seem to follow a convention
of their own, yet the files display perfectly in Ferret. Thus, when I
tried to use the addXML.sh tool, the following error was returned:
"File parsed.  No Lat/Lon grids found."

Can someone guide me as to how I can go about this? (i.e. modify parts
of the NetCDF file, use another scripting tool, etc.)

Below is the dump of one of the files:

==START==

netcdf 2D_001 {
dimensions:
     two = 2 ;
         three = 3 ;
         time = UNLIMITED ; // (84 currently)
         xaxis = 1320 ;
         yaxis = 1482 ;
         zaxis = 1 ;
         zip2 = 1149078 ;
         zip3 = 1099600 ;
variables:
     double time(time) ;
                 time:long_name = "coordinate variables of time" ;
                 time:units = "second since 2008-01-22" ;
                 time:figure = "na" ;
         float h(yaxis, xaxis) ;
                 h:long_name = "distance from still water level to sea
bed" ;
                 h:units = "meter" ;
                 h:figure = "scalar_h" ;
                 h:_FillValue = 9.96921e+36f ;
         float lon(yaxis, xaxis) ;
                 lon:long_name = "longitude(east)" ;
                 lon:units = "degree_east" ;
                 lon:figure = "na" ;
                 lon:_FillValue = 9.96921e+36f ;
         float lat(yaxis, xaxis) ;
                 lat:long_name = "latitude(north)" ;
                 lat:units = "degree_north" ;
                 lat:figure = "na" ;
                 lat:_FillValue = 9.96921e+36f ;
         float mask(yaxis, xaxis) ;
                 mask:long_name = "computational mask. 1 is a
computational cell, 0 is a land cell." ;
                 mask:units = "none" ;
                 mask:figure = "mask" ;
                 mask:_FillValue = 9.96921e+36f ;
         float e(time, yaxis, xaxis) ;
                 e:long_name = "water surface elevation from still
water level" ;
                 e:units = "meter" ;
                 e:figure = "scalar" ;
                 e:_FillValue = 9.96921e+36f ;
         float va(time, yaxis, xaxis) ;
                 va:long_name = "depth averaged current speed along
y-axis" ;
                 va:units = "meter/second" ;
                 va:figure = "vector_y" ;
                 va:_FillValue = 9.96921e+36f ;
         float ua(time, yaxis, xaxis) ;
                 ua:long_name = "depth averaged water current speed
along x-axis" ;
                 ua:units = "meter/second" ;
                 ua:figure = "vector_x" ;
                 ua:_FillValue = 9.96921e+36f ;

// global attributes:
                 :title = "standard output file number 1" ;
                 :institution = "university" ;
                 :source = "hydro program" ;
                 :comment =  "" ;
                 :format = "version 1.1" ;
                 :reference_point = "none" ;
                 :previous_file = "na" ;
                 :next_file = "2D_002.nc" ;
                 :created = "2010-02-17 12:35:04" ;
                 :first_record = "2008-01-23 00:00:00" ;
                 :last_record = "2008-01-23 20:45:00" ;
}

==END==
-- 
Regards,
Anton Yoel Buenavista
    

  






Attachment: Figure_1.png
Description: PNG image


[Thread Prev][Thread Next][Index]


Contact Us
Dept of Commerce / NOAA / OAR / PMEL / TMAP

Privacy Policy | Disclaimer | Accessibility Statement