code: def test_applies_activation(self, num_layers):
      activation = CountingActivation()
      mod = mlp.MLP([1] * num_layers, activation=activation)
      mod(tf.ones([1, 1]))
      self.assertEqual(activation.count, num_layers - 1)
  
imports: import itertools
  from absl.testing import parameterized
  from sonnet.src import test_utils
  from sonnet.src.nets import mlp
  import tensorflow
label_desc: Use image node_id 3 for calling the MLPTest obj's underlying member method code with example usage: obj.test_applies_activation(num_layers) without return types