text_plain_output_1.png image_output_1.png
from torch.utils.data import Dataset, random_split, DataLoader

batch_size = 50
input_size = 129 * 129
output_size = 12

train_dl = DataLoader(train_ds, batch_size, shuffle=True, num_workers=2, pin_memory=True)
val_dl = DataLoader(val_ds, batch_size * 2, num_workers=2, pin_memory=True)

for a, b in val_dl:
    print(a.shape, b.shape, sep='\n')
    break