Skip to content

omarmahamid/neural-network

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Neural Network from Scratch

This project implements a neural network from scratch in pure Java 21. The neural network is capable of training and testing using the MNIST dataset for digit recognition.

Features

  • Neural Network Implementation: The core of the project is the neural network implementation found in NeuralNetwork.
  • Training and Testing: The network can be trained and tested using the MNIST dataset. The training is done using stochastic gradient descent, implemented in StochasticGradientDescentTrainer.
  • Cost Functions: Different cost functions are available, such as the cross-entropy cost function in CrossEntropyCostFunction and the quadratic cost function in QuadraticCostFunction.
  • Activation Functions: The project includes various activation functions, such as the sigmoid function in SigmoidFunction.
  • Regularization: Regularization techniques like L1 and L2 regularization are implemented in L1Regularization and L2Regularization.
  • Data Handling: Utilities for handling data, such as shuffling and subdividing datasets, are provided in DataUtils.
  • MNIST Data Loader: The MNIST dataset loader is implemented in MNISTLoader.
  • GUI: A graphical user interface for drawing digits and interacting with the neural network is implemented in Frame, ButtonPanel, and DrawPanel.

Getting Started

Prerequisites

  • Java 21
  • Maven

Building the Project

To build the project, run the following command in the root directory:

mvn clean install

mvn exec:java -Dexec.mainClass="org.neural.network.testermodule.Frame"

About

neural network from scratch - written in pure java

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages