code: def test_array_object_type(BallTreeImplementation):
      """Check that we do not accept object dtype array."""
      X = np.array([(1, 2, 3), (2, 5), (5, 5, 1, 2)], dtype=object)
      with pytest.raises(
          ValueError, match="setting an array element with a sequence"
      ):
          BallTreeImplementation(X)
  
file_path: scikit-learn/sklearn/neighbors/tests/test_ball_tree.py
imports: import itertools
  import numpy
  import pytest
  from numpy.testing import assert_allclose, assert_array_almost_equal, assert_equal
  from sklearn.neighbors._ball_tree import BallTree, BallTree32, BallTree64
  from sklearn.utils import check_random_state
  from sklearn.utils._testing import _convert_container
  from sklearn.utils.validation import check_array
label_desc: Use image node_id 5 for calling a global function with example usage: test_array_object_type(BallTreeImplementation) without return types