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

Function chunk_max

dask/array/reductions.py:141–146  ·  view source on GitHub ↗

Version of np.max which ignores size 0 arrays

(x, axis=None, keepdims=None)

Source from the content-addressed store, hash-verified

139
140
141def chunk_max(x, axis=None, keepdims=None):
142 """Version of np.max which ignores size 0 arrays"""
143 if x.size == 0:
144 return array_safe([], x, ndmin=x.ndim, dtype=x.dtype)
145 else:
146 return np.max(x, axis=axis, keepdims=keepdims)
147
148
149@derived_from(np)

Callers

nothing calls this directly

Calls 2

array_safeFunction · 0.90
maxMethod · 0.45

Tested by

no test coverage detected