question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

check whether initialized calendar type equals calendar type of new file added by add_observations() and add_uninitialized()

See original GitHub issue

https://github.com/bradyrx/climpred/pull/294 currently converts all non xr.CFTimeIndex objects into cftime.ProlepticGregorian. This is problematic for instance if the model being used is on a noleap or 360day calendar.

The ideal case would be to encourage users to handle the cftime stuff on pre-processing. But we can also look for calendar attributes and so on to infer the calendar before converting.

I have a useful set of calendar-related functions here: https://github.com/bradyrx/esmtools/blob/master/esmtools/temporal.py

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
aaronspringcommented, Mar 1, 2020

basically we infer calendars now. PM uses Leap/NoLeap, hindcast Gregorian. Maybe we add a config.yaml with these defaults and a user that wants to change this can change it here.

0reactions
bradyrxcommented, Sep 24, 2020

Yes. For instance this came up in https://github.com/pangeo-data/climpred/issues/393. In the current system you could add a hindcast with calendar DatetimeNoLeap. then maybe you pull in observations with DatetimeGregorian. It would work but then alignment breaks bc xarray sees them as two different datetimes. So the error would just tell users to update the calendar, since calendar switching is not easy to automate.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Fullcalendar V4 get initialised calendar by documentId
Looks like we would need to create a global variable to hold each calendar. Is there a way to get the initialized calendar...
Read more >
FullCalendarVDom.render is throwing errors during calendar ...
Seems like both of these variables are undefined here and that's where the error happens. I opened the unminified FullCalendar and found plenty ......
Read more >
How to Create a New Calendar in Google Calendar - YouTube
In this video I will show you how to add or create a new calendar in ... create other calendars to help organize...
Read more >
Creating and customizing a new calendar - Google Calendar
In this video we are going to over how to create a new calendar using Google Calendar. After creating it, we are going...
Read more >
Initialize with Script Tags - Docs - FullCalendar
It's possible to manually include the necessary <script> tags in the head of your HTML page and then initialize a calendar via browser...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found