docstr: Tests the correct exceptions are raised for invalid shapes.
docstr_tok: ["Tests","the","correct","exceptions","are","raised","for","invalid","shapes","."]
code: def test_pool_exception_raised_shapes(
      self, err_msg, data_shape, pool_map_shape, sizes_shape
  ):
      """Tests the correct exceptions are raised for invalid shapes."""
      data = np.ones(data_shape, dtype=np.float32)
      pool_map = _dense_to_sparse(
          np.ones(pool_map_shape, dtype=np.float32)
      )
      if sizes_shape is not None:
          sizes = np.ones(sizes_shape, dtype=np.int32)
      else:
          sizes = None
  
      with self.assertRaisesRegexp(ValueError, err_msg):
          gp.pool(data, pool_map, sizes)
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import itertools
  from absl.testing import parameterized
  import numpy
  from six.moves import range
  import tensorflow
  import tensorflow_graphics.geometry.convolution.graph_pooling
  from tensorflow_graphics.geometry.convolution.tests import utils_test
  from tensorflow_graphics.util import test_case
label_desc: Use image node_id 2 for calling the GraphPoolingTestPoolTests obj's underlying member method code with example usage: obj.test_pool_exception_raised_shapes(err_msg, data_shape, pool_map_shape, sizes_shape) without return types