code: def assert_equal_records(a, b):
      """
      Asserts that two records are equal.
  
      Pretty crude for now.
  
      """
      assert_equal(a.dtype, b.dtype)
      for f in a.dtype.names:
          (af, bf) = (operator.getitem(a, f), operator.getitem(b, f))
          if not (af is masked) and not (bf is masked):
              assert_equal(
                  operator.getitem(a, f), operator.getitem(b, f)
              )
      return
  
imports: import operator
  import numpy
  from numpy import ndarray, float_
  import numpy.core.umath
  import numpy.testing
  from numpy.testing import assert_, assert_allclose, assert_array_almost_equal_nulp, assert_raises, build_err_msg
  from .core import mask_or, getmask, masked_array, nomask, masked, filled
  from unittest import TestCase
label_desc: Use image node_id 4 for calling a global function with example usage: assert_equal_records(a, b) without return types