def calendar(self):
        """The calendar used by the datetimes in the index."""
        from xarray.coding.times import infer_calendar_name

        if not self._data.size:
            return None

        return infer_calendar_name(self)
The calendar used by the datetimes in the index.
xarray/coding/cftimeindex.py