code: def test_CallableArray():
      callarray = CallableArray((2, 3), dtype=object)
  
      # Test without Nones
      callarray[:] = np.arange
      expected = np.empty([2, 3, 4])
      expected[:] = range(4)
      npt.assert_array_equal(callarray(4), expected)
  
      # Test with Nones
      callarray[0, 0] = None
      expected[0, 0] = 0
      npt.assert_array_equal(callarray(4), expected)
  
file_path: dipy/dipy/reconst/tests/test_multi_voxel.py
imports: from functools import reduce
  import numpy
  import numpy.testing
  from dipy.reconst.multi_voxel import _squash, multi_voxel_fit, CallableArray
  from dipy.core.sphere import unit_icosahedron
  from dipy.testing.decorators import set_random_number_generator
label_desc: Use image node_id 2 for calling a global function with example usage: test_CallableArray() without return types