ak.validity_error#
Defined in awkward.operations.ak_validity_error on line 12.
- ak.validity_error(array, *, exception=False)#
Returns an error message if the array has a structural error, or empty if valid.
Checks for errors in the structure of the array, such as indexes that run beyond the length of a node’s
content, etc. Either an error is raised or a string describing the error is returned.See also
ak.is_valid.- Parameters:
array – Array-like data (anything
ak.to_layoutrecognizes).exception (bool) – If True, validity errors raise exceptions.
- Returns:
An empty string if
arrayis valid, or a string describing the structural error otherwise.