(self, ufunc)
| 84 | } |
| 85 | |
| 86 | def __init__(self, ufunc): |
| 87 | if not isinstance(ufunc, (np.ufunc, da_frompyfunc)): |
| 88 | raise TypeError( |
| 89 | "must be an instance of `ufunc` or " |
| 90 | f"`da_frompyfunc`, got `{type(ufunc).__name__}" |
| 91 | ) |
| 92 | self._ufunc = ufunc |
| 93 | self.__name__ = ufunc.__name__ |
| 94 | if isinstance(ufunc, np.ufunc): |
| 95 | derived_from(np)(self) |
| 96 | |
| 97 | def __dask_tokenize__(self): |
| 98 | return self.__name__, normalize_token(self._ufunc) |
nothing calls this directly
no test coverage detected