MCPcopy Create free account
hub / github.com/dask/dask / _wrap_masked

Function _wrap_masked

dask/array/ma.py:30–40  ·  view source on GitHub ↗
(f)

Source from the content-addressed store, hash-verified

28
29
30def _wrap_masked(f):
31 @wraps(f)
32 def _(a, value):
33 a = asanyarray(a)
34 value = asanyarray(value)
35 ainds = tuple(range(a.ndim))[::-1]
36 vinds = tuple(range(value.ndim))[::-1]
37 oinds = max(ainds, vinds, key=len)
38 return blockwise(f, oinds, a, ainds, value, vinds, dtype=a.dtype)
39
40 return _
41
42
43masked_greater = _wrap_masked(np.ma.masked_greater)

Callers 1

ma.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected