MCPcopy Index your code
hub / github.com/pydata/xarray / _days_in_year

Function _days_in_year

xarray/coding/calendar_ops.py:240–244  ·  view source on GitHub ↗

The number of days in the year according to given calendar.

(years, calendar)

Source from the content-addressed store, hash-verified

238
239
240def _days_in_year(years, calendar):
241 """The number of days in the year according to given calendar."""
242 if calendar == "360_day":
243 return full_like(years, 360)
244 return _is_leap_year(years, calendar).astype(int) + 365
245
246
247def _interpolate_day_of_year(times, target_calendar):

Callers 2

_interpolate_day_of_yearFunction · 0.85
_random_day_of_yearFunction · 0.85

Calls 3

full_likeFunction · 0.90
_is_leap_yearFunction · 0.85
astypeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…