def num_examples(self):
    """The number of examples for each split."""
    if self.split == 'compositional_splits':
      example_count = {
          'train': 367933,
          'dev': 3716,
          'test': 19282,
          'visual': 37436,
          'situational_1': 88642,
          'situational_2': 16808,
          'contextual': 11460,
          'adverb_1': 112880,
          'adverb_2': 38582,
          'visual_easier': 18718,
      }
    elif self.split == 'target_length_split':
      example_count = {
          'train': 180301,
          'dev': 1821,
          'test': 37784,
          'target_lengths': 198588
      }
    elif self.split == 'spatial_relation_splits':
      example_count = {
          'train': 259088,
          'dev': 2617,
          'test': 28526,
          'visual': 62250,
          'relation': 6285,
          'referent': 30492,
          'relative_position_1': 41576,
          'relative_position_2': 41529
      }
    elif self.split == 'test':
      example_count = {'train': 8}
    else:
      raise RuntimeError(f'Unknown split {self.split}.')
    return example_count
The number of examples for each split.
language/gscan/xattn_model/dataset/gscan_dataset.py