class_docstr: Integration tests for clustering.
docstr: Verifies that stripping the clustering wrappers from a sequential model produces the expected config.
docstr_tok: ["Verifies","that","stripping","the","clustering","wrappers","from","a","sequential","model","produces","the","expected","config","."]
code: def testStripClusteringSequentialModelWithRegulariser(self):
      """Verifies that stripping the clustering wrappers from a sequential model produces the expected config."""
      original_model = keras.Sequential(
          [
              layers.Dense(5, input_shape=(5,)),
              layers.Dense(
                  5, kernel_regularizer=tf.keras.regularizers.L1(0.01)
              ),
          ]
      )
  
      def clusters_check(stripped_model):
          # dense layer
          weights_as_list = (
              stripped_model.get_weights()[0]
              .reshape(
                  -1,
              )
              .tolist()
          )
          unique_weights = set(weights_as_list)
          self.assertLessEqual(
              len(unique_weights), self.params["number_of_clusters"]
          )
  
      self.end_to_end_testing(original_model, clusters_check)
  
imports: import os
  import tempfile
  from absl.testing import parameterized
  import numpy
  import tensorflow
  from tensorflow_model_optimization.python.core.clustering.keras import cluster
  from tensorflow_model_optimization.python.core.clustering.keras import cluster_config
  from tensorflow_model_optimization.python.core.clustering.keras.experimental import cluster
label_desc: Use image node_id 14 for calling the ClusterIntegrationTest obj's underlying member method code with example usage: obj.testStripClusteringSequentialModelWithRegulariser() without return types