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

How to load mnist? #18

Open
liuliuqiu opened this issue Aug 14, 2016 · 1 comment
Open

How to load mnist? #18

liuliuqiu opened this issue Aug 14, 2016 · 1 comment

Comments

@liuliuqiu
Copy link

In your logistic regression ,from load import mnist?

@kiran-mohan
Copy link

kiran-mohan commented Aug 18, 2016

Hi @liuliuqiu

You can load mnist by following the instructions in this website. https://pypi.python.org/pypi/python-mnist/0.3

After you follow the procedure in the above website to install the package, to get trX, trY, teX, teY as in NewMu's tutorials, use the following code.

from mnist import MNIST
mndata = MNIST('/dir_with_mnist_data_files')
trX,trY = mndata.load_training()
teX,teY = mndata.load_testing()

Hope this helps.

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

No branches or pull requests

2 participants