inputs: # @title An example for loading Cats vs Dongs noisy label datasets
task_name = 'cats_vs_dogs'

# One of ['low', 'medium', 'high']
noise_level = 'medium'

# One of ['train', 'valid']. The `valid` split should be used for
# hyperparameter tuning. The model should be tested on the original test
# slipt for these tasks.
split = 'train'

# We have 10 rater models for Cats vs Dogs.
num_raters = 10

directory = os.path.join(root_dir, task_name, noise_level, split) + '*'
raw_image_dataset = tf.data.TFRecordDataset(tf.io.gfile.glob(directory))

# Create a dictionary describing the features.
image_feature_description = {
    # noisy labels from all the raters
    'noisy_labels': tf.io.FixedLenFeature([num_raters], tf.int64),
    # the IDs of rater models
    'rater_ids': tf.io.FixedLenFeature([num_raters], tf.string),
    # filename of the image
    'image/filename': tf.io.FixedLenFeature([1], tf.string),
}

def _parse_image_function(example_proto):
  # Parse the input tf.train.Example proto using the dictionary above.
  return tf.io.parse_single_example(example_proto, image_feature_description)

parsed_image_dataset = raw_image_dataset.map(_parse_image_function)

for features in parsed_image_dataset.take(1):
  # Check the IDs of the rater models. The rater IDs are the same for all the
  # examples in the dataset.
  rater_ids = features['rater_ids']
  rater_id_string = [r.numpy().decode('utf-8') for r in rater_ids]
  print('The IDs of the rater models for this dataset are:')
  print(rater_id_string)
  print('Image filename:')
  print(features['image/filename'][0].numpy().decode('utf-8'))
  noisy_labels = features['noisy_labels'].numpy()
  print('The noisy labels from the rater models are:')
  print(noisy_labels)

# @title An example for loading rater features
for task_name in ['cifar10', 'cifar100', 'patch_camelyon', 'cats_vs_dogs']:
  for noise_level in ['low', 'medium', 'high']:
    dir = os.path.join(root_dir, task_name, noise_level, 'rater_features.json')
    with tf.io.gfile.GFile(dir, 'rb') as fj:
     ...
Given the above code, generate some markdown instructions for it.

targets: 
Cats vs Dogs noisy label datasets
Download size
*   2.4MB for each of the low, medium, and high noise datasets.
Number of examples
*   train: 9302, valid: 1184, for each of the low, medium, and high noise datasets.
Both the train and valid splits are subsampled from the original Cats vs Dogs dataset.
Data features
*   "noisy_labels": the noisy label given by rater models, a list of 10 tf.int64 integers. Label 0 for cats, 1 for dogs.
*   "rater_ids": the ID of the rater models, a list of 10 tf.string.
*   "image/filename": the filename of the image, corresponding to the filename in the original Cats vs Dogs dataset, tf.string.
Rater features
*   model_name: name of the model
*   accuracy: accuracy of the rater model on the rater validation set
*   loss: loss of the rater model on the rater validation set
*   mAP: the mean average precision of the rater model on the rater validation set
*   auc_PR: the area under curve--precision recall of the rater model on the rater validation set
*   auc_ROC: the area under curve--ROC of the rater model on the rater validation set
*   experience: the total number of data that the rater model has seen during training