[ncl-talk] Issue with cd_inv_calendar return values
Kyle Griffin
ksgriffin2 at wisc.edu
Wed Jul 22 08:13:00 MDT 2015
Hi Saji,
How are you calling cd_inv_calendar in your code? Are you certain that
partial days (e.g., hours, minutes, and/or seconds not equal to 0) aren't
being fed into the function? I've used this function countless times with
"hours since xxx" and "days since xxxx" and never experienced the issue you
are describing.
Kyle
----------------------------------------
Kyle S. Griffin
Department of Atmospheric and Oceanic Sciences
University of Wisconsin - Madison
Room 1421
1225 W Dayton St, Madison, WI 53706
Email: ksgriffin2 at wisc.edu
On Tue, Jul 21, 2015 at 6:32 AM, Saji Hameed <saji.nh at gmail.com> wrote:
> Dear NCL developers,
>
> I have a library that uses cd_inv_calendar for some critical parts. Once
> in a blue moon, my
> script crashes due to problems with values returned by cd_inv_calendar.
> Instead of returning
> a whole number (for example 37785 days since 1900-01-01 return value is
> double), it sometimes returns a fraction (37784.xxxx).
>
> I use NCL version 6.3.0 on a Linux box.
>
> It is quite difficult to reproduce this issue because it happens rarely
> and randomly. I notice that
> http://www.ncl.ucar.edu/current_release.shtml#KnownBugs6.3.0 notes a bug
> with cd_calendar when the units are specified as "minutes since" or
> "seconds since". In my case the units are
> "days since 1900-01-01".
>
> I will use ut_calendar for the time being, but thought that I would notify
> the developers about this issue.
>
> saji
>
> _______________________________________________
> 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/20150722/d9bb5f8e/attachment.html
More information about the ncl-talk
mailing list