File size: 349 Bytes
8fd2f2f
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
from pathlib import Path
from torch.utils.data import Dataset

from dataloader.single_image_dataset import SingleImageDataset


class SingleImageDatasetFactory():

    def __init__(self, file: Path):
        self.data_path = file

    def get_dataset(self, max_samples: int = None) -> Dataset:
        return SingleImageDataset(file=self.data_path)