Skip to content

C++ Neural Network with Training Visualizer and Data Generation Tool

Notifications You must be signed in to change notification settings

000x999/Neural_Net

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

C++ Neural Network with Training Visualizer

A C++ implementation of a Neural Network, along with a real-time training visualizer and data generation tool. The project aims to visualize the error, gradient, and weight values as the neural network trains over iterations.

Features

  • A simple feedforward ANN with training using backpropagation and activation functions.
  • Real-Time Training Visualizer that visualizes error, gradients, and weights over iterations using a Python script.
  • Random Training Data Generator: A Python script to generate random training data in the required format.
  • Dual File/Terminal Output Logging.

How It Works:

Requirements

  • C++17 and newer: For building and running the neural network.
  • Python 3.x: Required for the visualizer and data generation scripts.
  • Matplotlib & Numpy.

Installation

Note:

  • Build instructions can be found below including installing python, matplotlib and numpy using the Python installer, Homebrew and apt for Windows, MacOS and linux respectively. Other build instructions and compiler flags are included as well.

Installing Python

Windows

  1. Download the latest Python installer from python.org
  2. Run the installer and check "Add Python to PATH" during setup.
  3. Verify installation by running in Command Prompt:
    python --version

macOS

  1. Open Terminal and install Python using Homebrew:

    brew install python
  2. Verify installation:

    python3 --version

Linux (Debian/Ubuntu)

  1. Open Terminal and run:

    sudo apt update
    sudo apt install python3 python3-pip
  2. Verify installation:

    python3 --version

Installing Required Python Libraries

Once Python is installed, install the required libraries (matplotlib and numpy):

pip install matplotlib numpy

Clone the Repository and Build

  1. Clone the repository:
    git clone https://github.com/000x999/Neural_Net
    cd Neural_Net
  2. Compile and run the program:
    Make sure to have 'Make' installed, 'GCC'/'G++' 
    Set your STL C++ header files 'Include' folder path in the CXXFLAGS section inside the Makefile.
    Simply run 'make' directly in the command line from within the 'Neural_Net' folder.
    To run any of the two python scripts, be sure to have numpy and matplotlib installed,
    then simply run 'py [scriptName.py]' directly in the command line

Releases

No releases published

Packages

No packages published