def METHOD_NAME(self):
    train_path = os.path.join(self.annotation_path, 'train2017')
    val_path = os.path.join(self.annotation_path, 'val2017')
    save_train_path = os.path.join(self.save_path, 'train2017')
    save_val_path = os.path.join(self.save_path, 'val2017')
    if not os.path.exists(save_train_path):
        os.makedirs(save_train_path)
    if not os.path.exists(save_val_path):
        os.makedirs(save_val_path)
    for label_id in tqdm(os.listdir(train_path), desc='trainset'):
        label = np.array(
            Image.open(os.path.join(train_path, label_id)).convert('P'))
        label = self.encode_label(label)
        label = Image.fromarray(label)
        label.save(os.path.join(save_train_path, label_id))
    for label_id in tqdm(os.listdir(val_path), desc='valset'):
        label = np.array(
            Image.open(os.path.join(val_path, label_id)).convert('P'))
        label = self.encode_label(label)
        label = Image.fromarray(label)
        label.save(os.path.join(save_val_path, label_id))