[Thread Prev][Thread Next][Index]
Re: [ferret_users] nc2mc.sh
Hi,
Thank you for your answer. I once used fortran program
to make .mc file before, it works on other nc files.
However, I check my current .nc files and found the
name of time axis of many nc files is different. I
think I need to unify the name (use the same axis in
the same name, x,y,z,t), then all these errors will
definitely avoid.
I have a way to change the axis name: first change cdf
files into ascii, then redefine the name of axes. But
it takes long time because I have about 1400 nc files,
each file has a size about 380MB. Do you have a method
that will change the name of axes within cdf file so
that I can save a lot of time?
Thank you so much!
Yangxing
--- Patrick Jöckel <joeckel@xxxxxxxxxxxxxxxxx> wrote:
> Dear Yangxing Zheng,
>
> nc2mc is a tcsh-script, it might be that you need to
> change
> the first line from
> #! /usr/bin/tcsh -f
> into
> #! /bin/tcsh -f
> or another path.
> You can check this with 'which tcsh' on your system.
> Then 'chmod u+x nc2mc' and run it with "./nc2mc".
>
> The list of files in this script is simply generated
> with
> set list0 = `echo *$namefrag*.nc`, i.e., the order
> of files is determined by
> the way how the tc-shell expands the '*'.
> Something like 'find' or an additional sorting might
> be better suited ...
>
> Now to your resulting mc-File:
> The first stepfile-record seems to be OK (does it
> contain only 1 time step ?),
> all others are strange.
>
> Four questions:
> Does the time axis in all of your files have the
> same name ?
> Is the time axis equidistant (and does it have the
> same unit ?) ?
> Which command line parameters did you apply (try
> 'nc2mc -h') ?
>
> The first two 'yes' are prerequisites to make nc2mc
> work!
>
> Can you provide the 'ncdump -c' of the first files
> in your list ?
>
> Yours,
>
> Patrick Joeckel
>
>
>
> On Thursday 13 December 2007 17:56, you wrote:
> > Hi,
> >
> > Thanks. You are right, I try ./nc2mc.sh instead
> of
> > nc2mc or ./nc2mc or nc2mc.sh on the prompt.
> >
> > Attached is the .mc file that is very strange.
> When
> > I run nc2mc.sh, there are errors:
> > /usr/local/bin/ncdump: Variable not found for each
> > time point.
> >
> > Any suggestions? I really need to know the usage
> of
> > nc2mc.sh. By the way, I use ferret V5.7 alpha
> (Mac),
> > based on the statement in the mannual "Previous to
> > version 5.2 Ferret performs sanity checking on the
> > data set by comparing these time coordinates with
> > those found in the data files as he data are read.
> In
> > version 5.3 and higher no sanity checks are
> performed.
> > This means that the MC descriptor mechanism can be
> > used to associate into time series groups of files
> > that are not internally self-documenting with
> respect
> > to time", the time in each nc file should be
> voided
> > and any time series should follows the .mc file.
> >
> > Can anyone tell me what is wrong with creating
> mc
> > file?
> >
> > Thanks a lot.
> >
> > Yangxing
> >
> > --- Roman Tonkonojenkov <romantonk@xxxxxxx> wrote:
> > > Hi Yangxing,
> > >
> > > Try this:
> > > $ chmod 777 nc2mc
> > > AND:{
> > > $ nc2mc.sh
> > > OR
> > > $ ./nc2mc.sh
> > > }
> > > If this still does not work, check the shebang
> (the
> > > first line of the script).
> > > If this is a bash script, it should
> > > say:
> > > #!/bin/bash
> > > The last word in the shebang is the shell under
> > > which it is supposed to be
> > > executed.
> > > Try switching to the shell, indicated by the
> > > shebang, and run the script in
> > > that shell
> > > (I assume you know how to do this...)
> > >
> > > Hope this helps...
> > > Roman
> > >
> > > On Wed, Dec 12, 2007 05:18 PM, yangxing zheng
> > > <yangxingz@xxxxxxxxx> wrote:
> > >
> > > Hi,
> > >
> > > > I try to convert a collection of nc files
> into
> > >
> > > .mc
> > >
> > > >file using the tool nc2mc. I download it from
> > > >http://www.mpch-mainz.mpg.de/~joeckel/nc2mc/
> > > >
> > > > My machine is Mac, I chmod 755 nc2mc, then
> on
> > >
> > > the
> > >
> > > >prompt, just simply type nc2mc ,
> > > >But it still does not work, error message:
> tcsh:
> > > >nc2mc.sh: Command not found. can anyone help?
> > > >
> > > > Thanks!
> > > >
> > > > Yangxing
> > >
> >
>
>__________________________________________________________________________
> > >__________
> > >
> > > >Be a better friend, newshound, and
> > > >know-it-all with Yahoo! Mobile. Try it now.
> >
> >
>
http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
>
___________________________________________________________________________
> >_________ Be a better friend, newshound, and
> > know-it-all with Yahoo! Mobile. Try it now.
> >
>
http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
>
> --
>
---------------------------------------------------------------
> Dr. Patrick Joeckel
> Max Planck Institute for Chemistry
> Joh.-J. Becher Weg 27
> 55128 Mainz phone:++49-6131-305452
>
> Germany fax :++49-6131-305436
>
>
> e-mail:joeckel@xxxxxxxxxxxxxxxxx
>
> http://www.mpch-mainz.mpg.de/~joeckel
>
---------------------------------------------------------------
>
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce /
NOAA /
OAR /
PMEL /
TMAP
Privacy Policy | Disclaimer | Accessibility Statement