Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add mnist #22

Merged
merged 1 commit into from
Jan 17, 2017
Merged

add mnist #22

merged 1 commit into from
Jan 17, 2017

Conversation

rtqichen
Copy link
Contributor

@rtqichen rtqichen commented Jan 5, 2017

Adds MNIST dataset. Seems to be working, at least for my own experiments. Resolves #13.

import torchvision.datasets as dset
training_data = dset.MNIST('data/mnist', train=True, transform=transforms.ToTensor(), download=True)
training_loader = torch.utils.data.DataLoader(training_data, batch_size=32, shuffle=True, num_workers=4)

By default, returns a grayscale PIL Image (mode L). Works with the ToTensor() transform and DataLoader.

@apaszke
Copy link
Contributor

apaszke commented Jan 6, 2017

@soumith @colesbury how about not returning PIL images from this one? I don't think we always need to return the same type

@apaszke apaszke merged commit 8bdbca7 into pytorch:master Jan 17, 2017
@apaszke
Copy link
Contributor

apaszke commented Jan 17, 2017

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants