Skip to content

snowsong42/PyTorch-MNIST-Tutorial

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyTorch-MNIST-Tutorial

PyTorch MNIST 手写数字识别教程

Python 3.8+ PyTorch 1.9+ License MIT GitHub stars

Quick Start

1. Clone the repository

git clone https://github.com/KevinLikesCodingMC/PyTorch-MNIST-Tutorial.git

2. Install requirements

First download the MNIST dataset in CSV format and place mnist_train.csv and mnist_test.csv in the root directory:

PyTorch-MNIST-Tutorial/
├── LICENSE
├── model.pth
├── model.py
├── README.md
├── test.py
├── train.py
├── utils.py
├── demo.py
├── mnist_train.csv
└── mnist_test.csv

Then install these packages:

pip install numpy matplotlib pygame

3. Install PyTorch

Visit PyTorch official website.

4. Training and Testing

Run train.py to train and generate model model.pth.

Run test.py to test the model model.pth.

5. Visual Demo

Run demo.py to watch the visual demo.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%