This repository contains implementations of core Machine Learning algorithms from scratch using Python and NumPy to understand how code works behind sklearn library. The goal of this project is to understand the mathematics, logic, and workflow behind commonly used ML algorithms.
- Implemented using the Gradient Descent
- Predicts continuous values
- Evaluated using R² score
- Binary classification (0 / 1)
- Uses sigmoid function
- Probability-based classification
- Evaluated using accuracy
- Distance-based (lazy learning) algorithm
- Uses Euclidean distance
- Majority voting for classification
- Small synthetic datasets created manually
- 2D feature space for better visualization and understanding
- Separate sample files for each algorithm
- Python
- NumPy
- Pandas
- Matplotlib / Seaborn
- Jupyter Notebook
- Git & GitHub
- Clone the repository: git clone https://github.com/sonakshigupta29/ML_Algorithm_Scratch_Implementation.git
- Navigate to the project directory: cd ML_Algorithm_Scratch_Implementation
- Open Jupyter Notebook: jupyter notebook
- Run any *_main.ipynb file to see the implementation and results.
- Add algorithms such as Softmax Regression, Polynomial Regression, and Neural Networks as I continue learning.
- Introduce model optimizations like train–test split, better evaluation metrics, performance analysis and etc to gain insight into how machine learning algorithms work behind the scenes.