def get_num_eval_images(hparams):
  """Returns the number of eval images according to the dataset."""
  num_images_map = {
      'imagenet': 50000,
      'cifar10': 10000,
  }
  if hparams.input_data.input_fn not in num_images_map:
    raise ValueError(
        f'Unknown dataset size for input_fn {hparams.input_data.input_fn}')

  return num_images_map[hparams.input_data.input_fn]