code: def test_generate_equi_width_histogram(self):
      expected_result = text_format.Parse(
          """
          buckets {
            low_value: 1.0
            high_value: 2.5
            sample_count: 38.25
          }
          buckets {
            low_value: 2.5
            high_value: 4.0
            sample_count: 21.75
          }
          type: STANDARD
          """,
          statistics_pb2.Histogram(),
      )
      result = quantiles_util.generate_equi_width_histogram(
          quantiles=np.array(
              [1.0, 2.0, 2.0, 2.0, 3.0, 3.0, 4.0], dtype=np.float32
          ),
          cumulative_counts=np.array([1, 34, 34, 34, 51, 51, 60]),
          finite_min=1,
          finite_max=4,
          num_buckets=2,
          num_pos_inf=0,
      )
      self.assertEqual(result, expected_result)
  
imports: from typing import List
  from absl.testing import absltest
  from absl.testing import parameterized
  import numpy
  from tensorflow_data_validation.utils import quantiles_util
  from google.protobuf import text_format
  from tensorflow_metadata.proto.v0 import statistics_pb2
label_desc: Use image node_id 5 for calling the QuantilesUtilTest obj's underlying member method code with example usage: obj.test_generate_equi_width_histogram() without return types