code: def test_matmul_and_same_scale_ptq_model(
      self,
      same_scale_op: str,
  ):
      input_shape = (2, 3, 1, 1024)
      filter_shape = (2, 3, 1024, 3)
      static_input_shape = [
          dim if dim is not None else 2 for dim in input_shape
      ]
  
      model = self._create_matmul_and_same_scale_model(
          input_shape,
          filter_shape,
          self._input_saved_model_path,
          same_scale_op,
      )
  
      rng = np.random.default_rng(seed=1235)
      input_data = ops.convert_to_tensor(
          rng.uniform(
              low=0.0, high=1.0, size=static_input_shape
          ).astype(np.float32)
      )
  
      def data_gen() -> repr_dataset.RepresentativeDataset:
          for _ in range(100):
              yield {
                  "input_tensor": rng.uniform(
                      low=0.0, high=1.0, size=static_input_shape
                  ).astype(np.float32)
              }
  
      dataset_path = self.create_tempfile("tfrecord").full_path
      path_map = {"serving_default": dataset_path}
      repr_dataset.TfRecordRepresentativeDatasetSaver(path_map).save(
          {"serving_default": data_gen()}
      )
  
      config = qc.QuantizationConfig(
          static_range_ptq_preset=qc.StaticRangePtqPreset(
              representative_datasets=[
                  qc.RepresentativeDatasetConfig(
                      tf_record=qc.TfRecordFile(path=dataset_path)
                  )
              ]
          ),
          tf_saved_model=qc.TfSavedModelConfig(
              tags=[tag_constants.SERVING]
          ),
      )
      quantization.quantize_saved_model(
          self._input_saved_model_path,
          self._output_saved_model_path,
          config,
      )
  
      expected_outputs = model.matmul_and_same_scale(input_data)
  
      root = load.load(self._output_saved_model_path)
      self.assertCountEqual(root.signatures.keys(), {"serving_default"})
  
      new_outputs = root.signatures["serving_default"](
          input_tensor=ops.convert_to_tensor(input_data)
      )
      # Tests that the quantized graph outputs similar values. The rtol and atol
      # values are arbitrary.
      self.assertAllClose(
          new_outputs, expected_outputs, rtol=0.03, atol=0.2
      )
  
imports: import itertools
  from typing import Optional, Sequence
  from absl.testing import parameterized
  import numpy
  from tensorflow.compiler.mlir.quantization.stablehlo import quantization_config_pb2
  from tensorflow.compiler.mlir.quantization.stablehlo.python import quantization
  from tensorflow.compiler.mlir.quantization.stablehlo.python.integration_test import quantize_model_test_base
  from tensorflow.compiler.mlir.quantization.tensorflow.python import representative_dataset
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.platform import test
  from tensorflow.python.saved_model import load
  from tensorflow.python.saved_model import tag_constants
label_desc: Use image node_id 2 for calling the StaticRangeQuantizationTest obj's underlying member method code with example usage: obj.test_matmul_and_same_scale_ptq_model(same_scale_op) without return types