text_plain_output_1.png
import os

image_path = '/content/dataset/semantic_drone_dataset/original_images'
mask_path = '/content/dataset/semantic_drone_dataset/label_images_semantic'

length = len(os.listdir(image_path))

train_dataset_len = int(length * 0.7)
val_dataset_len = length - train_dataset_len
train_dataset = DroneDataset(image_path, mask_path, train_dataset_len)
val_dataset = DroneDataset(image_path, mask_path, val_dataset_len, is_val=True)

train_dataset[5][1].shape