You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using cftime through xarray and one my computation returns an array where the values are dates. I want to get the number of days between these dates and a reference date. Some of the pixels of the input array are masked and set to np.nan and when doing the subtraction, it raises an error TypeError: unsupported operand type(s) for -: 'float' and 'cftime._cftime_Datetime360Day.
I was wondering if there is recommended way to handle invalid values with cftime, or a plan to support this? Maybe cftime.datetime could return numpy.NaT when the other object is either numpy.nan or numpy.NaT?