MovingMNIST¶
- class torchvision.datasets.MovingMNIST(root: Union[str, Path], split: Optional[str] = None, split_ratio: int = 10, download: bool = False, transform: Optional[Callable] = None)[source]¶
MovingMNIST Dataset.
- Parameters:
root (str or
pathlib.Path
) – Root directory of dataset whereMovingMNIST/mnist_test_seq.npy
exists.split (string, optional) – The dataset split, supports
None
(default),"train"
and"test"
. Ifsplit=None
, the full data is returned.split_ratio (int, optional) – The split ratio of number of frames. If
split="train"
, the first split framesdata[:, :split_ratio]
is returned. Ifsplit="test"
, the last split framesdata[:, split_ratio:]
is returned. Ifsplit=None
, this parameter is ignored and the all frames data is returned.transform (callable, optional) – A function/transform that takes in a torch Tensor and returns a transformed version. E.g,
transforms.RandomCrop
download (bool, optional) – If true, downloads the dataset from the internet and puts it in root directory. If dataset is already downloaded, it is not downloaded again.
- Special-members: