A web application that uses a neural network to recognize hand-drawn digits between 1 and 10.
This project combines a PyTorch-based neural network with a Next.js frontend to create an interactive digit recognition application. Users can draw a digit on a canvas, and the application will predict the drawn number in real-time.
- Interactive canvas for drawing digits
- Real-time prediction using a trained neural network
- Brutalist design aesthetic
- Responsive layout for both desktop and mobile devices
- Informative modal explaining the project's purpose and technology stack
- Frontend: Next.js, React, TypeScript
- Styling: Tailwind CSS
- Backend: Flask
- Machine Learning: PyTorch
- Dataset: MNIST
- The user draws a digit on the canvas.
- The frontend sends the image data to the Flask backend.
- The backend processes the image using a trained PyTorch model.
- The prediction is sent back to the frontend and displayed in real-time.
- Node.js
- Python 3.x
- pip
-
Clone the repository:
git clone https://github.com/yourusername/neural-network-digit-recognizer.git cd neural-network-digit-recognizer -
Install frontend dependencies:
npm install -
Install backend dependencies:
pip install -r requirements.txt
-
Start the development server:
npm run dev -
Open your browser and navigate to
http://localhost:3000
This application is designed to be deployed on Vercel. Follow the Vercel documentation for deploying Next.js applications with API routes.
Contributions are welcome! Please feel free to submit a Pull Request.
This project is open source and available under the MIT License.
- MNIST dataset for providing the training data
- Next.js and Flask for providing robust frameworks
- Vercel for hosting and deployment
