Re: Special needs when reading netCDF4 files in NCL?

From: Capehart, William J <William.Capehart_at_nyahnyahspammersnyahnyah>
Date: Thu Mar 06 2014 - 19:02:34 MST

Hi Wei

Dennis send me something offline (recommending ) but I'm sending what I sent back to him w.r.t the troubleshooting to you...

Email text is here:

I spent this AM fighting with the code and was able to get a little
traction but am still running into trouble.

One thing I AM seeing is that when I include reading a variable and
crunching on it (e.g., to do trivial unit conversions, we get

For example:
      rainc = f->RAINC(0,:,:) / 25.4 ; (Time,
south_north, west_east)

Will earn a Segmentation Fault, but when we break it down into separate
steps©

   rainc = f->RAINC(0,:,:)
   rainc = rainc / 25.4

©It passes.

We fixed that in our affected scripts and those patches are providing good
results.

But when we use addfiles(), the 'plural' of addfile() we get a new
segmentation fault that we cannot decode as soon as we input the data
through:

FOO = f[:]->BAR

Or

uvmetwrf3d = Wrf_user_getvar(f,"uvmet",-1)

Any ideas here? Are multiple file reads not supported for HDF (netCDF4)
files?

Cheers and Thanks
================================================================
Bill Capehart <William.Capehart@sdsmt.edu<mailto:William.Capehart@sdsmt.edu>> Associate Professor
Department of Atmospheric & Envir. Sciences AES PhD Coordinator
213 Mineral Industries Building Skype/EVO: wcapehart
South Dakota School of Mines and Technology Ph: +1-605-394-1994
501 East Saint Joseph Street Fax: +1-605-394-6061
Rapid City, SD 57701-3995 Mobile: +1-605-484-5692
=================== http://capehart.sdsmt.edu<http://capehart.sdsmt.edu/> ==================

From: Wei Huang <huangwei@ucar.edu<mailto:huangwei@ucar.edu>>
Date: Thursday, March 6, 2014 at 09:14 MST
To: William Capehart <William.Capehart@sdsmt.edu<mailto:William.Capehart@sdsmt.edu>>
Cc: Tabish Ansari <tabishumaransari@gmail.com<mailto:tabishumaransari@gmail.com>>, "ncl-talk@ucar.edu<mailto:ncl-talk@ucar.edu>" <ncl-talk@ucar.edu<mailto:ncl-talk@ucar.edu>>
Subject: Re: Special needs when reading netCDF4 files in NCL?

Bill,

For just reading, you do not need to use the setfileoption procedure,
as NCL can detect and automatically read NetCDF3 or NetCDF4.
But, for writing, that option will enforce NCL to write NetCDF4 file.

Could you please provide us more details of the error message,
or a sample file?

Thanks,

Wei

huangwei@ucar.edu<mailto:huangwei@ucar.edu>
VETS/CISL
National Center for Atmospheric Research
P.O. Box 3000 (1850 Table Mesa Dr.)
Boulder, CO 80307-3000 USA
(303) 497-8924

On Mar 6, 2014, at 9:05 AM, "Capehart, William J" <William.Capehart@sdsmt.edu<mailto:William.Capehart@sdsmt.edu>> wrote:

I am indeed using 6.1.2.

Bill

From: Tabish Ansari <tabishumaransari@gmail.com<mailto:tabishumaransari@gmail.com>>
Date: Thursday, March 6, 2014 at 06:37 MST
To: William Capehart <William.Capehart@sdsmt.edu<mailto:William.Capehart@sdsmt.edu>>
Cc: "ncl-talk@ucar.edu<mailto:ncl-talk@ucar.edu>" <ncl-talk@ucar.edu<mailto:ncl-talk@ucar.edu>>
Subject: Re: Special needs when reading netCDF4 files in NCL?

Start using NCL version 6.1.2

On 6 March 2014 11:36, Capehart, William J <William.Capehart@sdsmt.edu<mailto:William.Capehart@sdsmt.edu>> wrote:
I am having difficulty in applying the same NCL scripts I normally use for wrf output with netCDF3-type netcdf files and those with the netCDF4 option enabled.

This comes through when doing seemingly simple operations using the addfile and addfiles (for multiple files). Segmentation faults begin to appear on reading netcdf4 variables. Are there any special considerations other than including the line...

 setfileoption("nc", "Format", "NetCDF4").

Thanks Much,

================================================================
Bill Capehart <William.Capehart@sdsmt.edu<mailto:William.Capehart@sdsmt.edu>> Associate Professor
Department of Atmospheric & Envir. Sciences AES PhD Coordinator
213 Mineral Industries Building Skype/EVO: wcapehart
South Dakota School of Mines and Technology Ph: +1-605-394-1994
501 East Saint Joseph Street Fax: +1-605-394-6061
Rapid City, SD 57701-3995 Mobile: +1-605-484-5692
=================== http://capehart.sdsmt.edu<http://capehart.sdsmt.edu/> ==================

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk

--
Thanks & Regards
Tabish Umar Ansari
MS Research Scholar
Environmental & Water Resources Engineering Division
Department of Civil Engineering
IIT Madras
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Thu Mar 6 19:05:07 2014

This archive was generated by hypermail 2.1.8 : Fri Mar 14 2014 - 15:08:52 MDT