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.
- Host: GitHub
- URL: https://github.com/dhruvbavaliya13/neural-network
- Owner: DhruvBavaliya13
- Created: 2025-07-21T08:14:44.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-07-21T08:30:53.000Z (12 months ago)
- Last Synced: 2025-07-21T10:20:06.074Z (12 months ago)
- Topics: neural-network, python, scratch, tensorflow
- Language: Jupyter Notebook
- Homepage:
- Size: 198 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
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:

## 📁 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!