MCPcopy
hub / github.com/mne-tools/mne-python / _array_equal_nan

Function _array_equal_nan

mne/utils/numerics.py:748–757  ·  view source on GitHub ↗
(a, b, allclose=False)

Source from the content-addressed store, hash-verified

746
747
748def _array_equal_nan(a, b, allclose=False):
749 try:
750 if allclose:
751 func = np.testing.assert_allclose
752 else:
753 func = np.testing.assert_array_equal
754 func(a, b)
755 except AssertionError:
756 return False
757 return True
758
759
760def object_diff(a, b, pre="", *, allclose=False):

Callers 2

test_array_equal_nanFunction · 0.90
object_diffFunction · 0.85

Calls 1

funcFunction · 0.50

Tested by 1

test_array_equal_nanFunction · 0.72