A comprehensive collection of educational Jupyter notebooks exploring fundamental concepts of deep learning, neural networks, and optimization techniques from scratch.
This repository contains hands-on implementations and demonstrations of core deep learning concepts including neurons, layers, backpropagation, regularization, and various optimization algorithms. Perfect for students and practitioners looking to understand how neural networks work under the hood.
Deep dive into the backpropagation algorithm using a single neuron.
- ReLU activation function and its derivative
- Forward pass computation
- Gradient calculation via chain rule
- Weight and bias updates using backpropagation
- Key Concepts: Backpropagation, Gradient descent, Chain rule
Implementation of a fully connected (Dense) layer as a Python class.
- Dense layer architecture with multiple inputs and neurons
- Forward propagation through multiple layers
- ReLU activation implementation as a separate class
- Stacking multiple dense layers
- Key Concepts: Neural network layers, Matrix operations, Activation functions
Comprehensive exploration of individual neural network components.
- Breaking down neural network operations into modular functions
- Understanding each component's role in the network
- Key Concepts: Modularity, Function composition
Study of regularization techniques to prevent overfitting.
- L1 (Lasso) regularization
- L2 (Ridge) regularization
- Impact on model training and generalization
- Key Concepts: Overfitting prevention, Weight penalties, Model complexity control
Foundation concepts of neurons and network layers.
- Single neuron computations
- Multiple neurons in a layer
- Layer composition and connectivity
- Key Concepts: Neurons, Network topology, Forward pass
Detailed implementation and comparison of optimization algorithms.
- Momentum-based optimization
- Adaptive learning rate methods
- Softmax activation for multi-class classification
- Key Concepts: Optimization algorithms, Convergence, Learning rates
End-to-end classification example using the spiral dataset.
- Loading and visualizing the spiral dataset
- Building a neural network classifier
- Training and evaluation
- Key Concepts: Classification, Data visualization, Model training
- Python 3.7+
- Jupyter Notebook or JupyterLab
- NumPy
- Matplotlib
- NNFS (Neural Networks from Scratch library)
# Clone the repository
git clone https://github.com/PR202111/ML_Deep_learning.git
cd ML_Deep_learning
# Install required packages
pip install numpy matplotlib nnfs# Start Jupyter Lab
jupyter lab
# Or start Jupyter Notebook
jupyter notebookThen navigate to the notebook you want to explore and open it.
We recommend following these notebooks in order for optimal learning:
- Start Here →
BackProp_Neuron.ipynb- Understand the basics of backpropagation - Next →
Neurons_layers.ipynb- Learn about neurons and layers - Build Skills →
Dense_layer_class.ipynb- Implement dense layers - Deepen Understanding →
each_function_NN.ipynb- Explore individual components - Advanced Topics →
Optimizers.ipynb- Study optimization algorithms - Refinement →
L1_L2_Regularization.ipynb- Learn regularization techniques - Practice →
spiral_data_classification.ipynb- Apply everything to a real problem
- Neural Network Fundamentals: Neurons, layers, and network architecture
- Backpropagation: Forward and backward passes, gradient computation
- Activation Functions: ReLU, Softmax
- Loss Functions: Mean squared error, Cross-entropy
- Optimization: Gradient descent, Momentum, Adaptive methods
- Regularization: L1/L2 penalties to prevent overfitting
- Classification: Multi-class problems and softmax
- Practical Implementation: Building networks from scratch
- NumPy: Numerical computing and linear algebra
- Matplotlib: Data visualization
- NNFS: Neural Networks from Scratch utilities
- Jupyter: Interactive computing environment
After exploring these notebooks, you'll be able to:
- Understand how neural networks learn through backpropagation
- Implement neural network layers from scratch
- Apply various optimization algorithms effectively
- Use regularization to improve model generalization
- Build and train classifiers for multi-class problems
- Debug and understand neural network behavior
Each notebook is self-contained but builds upon concepts introduced in earlier notebooks. The code is heavily commented to aid understanding. Don't hesitate to modify and experiment with the code!
Feel free to fork this repository, add improvements, or suggest enhancements. This is an educational project meant to help others learn deep learning fundamentals.
- Neural Networks from Scratch
- 3Blue1Brown Neural Networks
- Deep Learning textbooks and academic papers
This project is open source and available under the MIT License.
Created by: PR202111
Last Updated: 2026
Status: Active ✨
Happy Learning! 🚀