An open API service indexing awesome lists of open source software.

https://github.com/dhruvbavaliya13/neural-network

This project demonstrates a simple neural network implementation from scratch using Python and NumPy, without relying on high-level frameworks like TensorFlow or PyTorch. It showcases a hands-on understanding of core neural network concepts including forward propagation, backpropagation, activation functions, loss calculation, and weight updates.
https://github.com/dhruvbavaliya13/neural-network

neural-network python scratch tensorflow

Last synced: about 2 months ago
JSON representation

This project demonstrates a simple neural network implementation from scratch using Python and NumPy, without relying on high-level frameworks like TensorFlow or PyTorch. It showcases a hands-on understanding of core neural network concepts including forward propagation, backpropagation, activation functions, loss calculation, and weight updates.

Awesome Lists containing this project

README

          

# Neural Network from Scratch 🧠

This project is a basic implementation of a feedforward neural network built entirely from scratch using Python and NumPy — without any machine learning frameworks like TensorFlow, Keras, or PyTorch.

## 🚀 Features

- Simple feedforward neural network
- Forward and backward propagation
- Sigmoid activation function
- Log loss
- Written for learning and demonstration purposes

## 🧠 How It Works

1. **Initialize Weights** – Randomly initialize weights and biases.
2. **Forward Pass** – Calculate outputs using activation functions.
3. **Loss Calculation** – Compute error using Log Loss.
4. **Backward Pass** – Adjust weights using the derivative of the loss.
5. **Repeat** – Train over multiple epochs.

## 📊 Example Output

Trained on the dataset:
image

## 📁 Project Structure
Neural-Network/
├── insurance_data.csv # Insurance small dataset
├── NN_from_Scratch.ipynb # Jupyter Notebook
├── nn.jpg # NN explanation img
├── logloss.png # Log loss formula img
└── README.md # Project documentation

## 📦 Requirements

- Python
- NumPy
- Pandas
- sklearn

## ▶️ How to run
python NN_from_Scratch.ipynb

## 📚 Learning Goals
This project helped me understand:

How neural networks learn via backpropagation

How to implement gradient descent manually

Core building blocks of deep learning

🌟 Inspiration
I built this project to solidify my understanding of neural networks at the mathematical and code level, and to learn how modern deep learning models are built from the ground up.

🔗 Connect With Me
📧 Dhruv Bavaliya
📬 Feel free to contribute or fork this project if you're learning like me!