class_docstr: Tests shape-related utility functions.
      
docstr: Tests :func:`texar.tf.utils.shapes.mask_sequences`.
          
code: def test_mask_sequences(self):
      """Tests :func:`texar.tf.utils.shapes.mask_sequences`."""
      seq = np.ones([3, 4, 3], dtype=np.int32)
      seq_length = np.array([3, 2, 1], dtype=np.int32)
  
      masked_seq = shapes.mask_sequences(seq, seq_length)
      self.assertEqual(masked_seq.shape, seq.shape)
      seq_sum = np.sum(masked_seq, axis=(1, 2))
      np.testing.assert_array_equal(seq_sum, seq_length * 3)
  
file_path: texar/tests/utils/shapes_test.py
imports: import numpy
  import tensorflow
  from texar.tf.utils import shapes
label_desc: Use image node_id 1 for calling the ShapesTest obj's underlying member method code with example usage: obj.test_mask_sequences() without return types