I am using the following code for loading MNST dataset but I cannot load SVHN dataset. Can you help me please to solve the problem?
train_dataset = datasets.MNIST(’…/data’, train=True, download=True, transform=dataset_transform)
train_loader = torch.utils.data.DataLoader(train_dataset, batch_size=batch_size, shuffle=True)
When I use
train_dataset = datasets.SVHN(’…/data’, train=True, download=True, transform=dataset_transform)
train_loader = torch.utils.data.DataLoader(train_dataset, batch_size=batch_size, shuffle=True)
I got the following error.
Traceback (most recent call last):
File “main.py”, line 45, in
test_dataset = datasets.SVHN(’…/data’, train=False, download=True, transform=dataset_transform)
TypeError: init() got an unexpected keyword argument ‘train’