MCPcopy Index your code
hub / github.com/numpy/numpy / _none_or_positive_arg

Function _none_or_positive_arg

numpy/_core/arrayprint.py:978–983  ·  view source on GitHub ↗
(x, name)

Source from the content-addressed store, hash-verified

976 recurser = None
977
978def _none_or_positive_arg(x, name):
979 if x is None:
980 return -1
981 if x < 0:
982 raise ValueError(f"{name} must be >= 0")
983 return x
984
985class FloatingFormat:
986 """ Formatter for subtypes of np.floating """

Callers 3

__init__Method · 0.85
format_float_scientificFunction · 0.85
format_float_positionalFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…