code: def test_object_array_of_0d(self):
      # gh-7864
      assert_raises(
          (RuntimeError, ValueError),
          histogram,
          [np.array(0.4) for i in range(10)] + [-np.inf],
      )
      assert_raises(
          (RuntimeError, ValueError),
          histogram,
          [np.array(0.4) for i in range(10)] + [np.inf],
      )
  
      # these should not crash
      np.histogram(
          [np.array(0.5) for i in range(10)] + [0.500000000000001]
      )
      np.histogram([np.array(0.5) for i in range(10)] + [0.5])
  
imports: import functools
  from unittest import expectedFailure, skipIf
  from pytest import raises
  from torch.testing._internal.common_utils import instantiate_parametrized_tests, parametrize, run_tests, slowTest, TEST_WITH_TORCHDYNAMO, TestCase, xpassIfTorchDynamo
label_desc: Use image node_id 20 for calling the TestHistogram obj's underlying member method code with example usage: obj.test_object_array_of_0d() without return types