MCPcopy Create free account
hub / github.com/numpy/numpy / _recursive_filled

Function _recursive_filled

numpy/ma/core.py:2475–2486  ·  view source on GitHub ↗

Recursively fill `a` with `fill_value`.

(a, mask, fill_value)

Source from the content-addressed store, hash-verified

2473
2474
2475def _recursive_filled(a, mask, fill_value):
2476 """
2477 Recursively fill `a` with `fill_value`.
2478
2479 """
2480 names = a.dtype.names
2481 for name in names:
2482 current = a[name]
2483 if current.dtype.names is not None:
2484 _recursive_filled(current, mask[name], fill_value[name])
2485 else:
2486 np.copyto(current, fill_value[name], where=mask[name])
2487
2488
2489def flatten_structured_array(a):

Callers 1

filledMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected