code: def testReplaceSingleLayerWithSingleLayer_MatchParameters(
      self, model_type
  ):
      class RemoveBiasInDense(transforms.Transform):
          """Replaces Dense layers with matching layers with `use_bias=False`."""
  
          def pattern(self):
              return LayerPattern("Dense", {"use_bias": True})
  
          def replacement(self, match_layer):
              match_layer_config = match_layer.layer["config"]
              # Remove bias
              match_layer_weights = match_layer.weights
              match_layer_weights.popitem()
  
              match_layer_config["use_bias"] = False
              new_dense_layer = keras.layers.Dense(**match_layer_config)
  
              replace_layer = quantize_utils.serialize_layer(
                  new_dense_layer, use_legacy_format=True
              )
              replace_layer["name"] = replace_layer["config"]["name"]
  
              return LayerNode(replace_layer, match_layer_weights, [])
  
      model = self._simple_dense_model(model_type)
  
      transformed_model, _ = ModelTransformer(
          model, [RemoveBiasInDense()]
      ).transform()
  
      # build_input_shape is a TensorShape object and the two objects are not
      # considered the same even though the shapes are the same.
      self._assert_config(
          model.get_config(),
          transformed_model.get_config(),
          ["use_bias", "build_input_shape"],
      )
  
      first_noninput_layer = self._get_layer(
          transformed_model, 0, model_type
      )
      self.assertFalse(first_noninput_layer.use_bias)
  
      # Should match since bias is initialized with zeros.
      self._assert_model_results_equal(model, transformed_model)
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from absl.testing import parameterized
  import numpy
  import tensorflow
  from tensorflow_model_optimization.python.core.quantization.keras import utils
  from tensorflow_model_optimization.python.core.quantization.keras.graph_transformations import model_transformer
  from tensorflow_model_optimization.python.core.quantization.keras.graph_transformations import transforms
label_desc: Use image node_id 11 for calling the ModelTransformerTest obj's underlying member method code with example usage: obj.testReplaceSingleLayerWithSingleLayer_MatchParameters(model_type) and returns: LayerPattern, LayerNode