/ML-From-Scratch

Some Machine Learning algorithms implemented by me, mostly from scratch.

Primary LanguageJupyter NotebookMIT LicenseMIT

Machine Learning Algorithms From Scratch

This is mostly a 'practice' repository, containing some ML algorithms which I have implemented from scratch. Why? because:

“What I cannot create, I do not understand”
~ Richard Feynman

I'll keep updating this repo as and when I learn new algorithms and implement it.

  1. K Nearest Neighbours: Recommends movies from the TMDB 5000 movies dataset based on the list of genres given as input.

  1. Logistic Regression: Predicts how likely peope are to buy a product based on their gender, age, and salary.

  1. Simple Neural Network: 2-layered neural network which mimics the XOR gate, implemented(vectorized) from scratch using NumPy.

  1. Digit Classification: Dataset used: MNIST
    • Contains a binary classifier that labels all 0s as 1 and rest all digits as 0.
    • Also contains an extension of the above classifier that classifies all 10 digits with an accuracy of 94%.
    • Both of the above networks are 2-layered and are implemented(vectorized) from scratch using NumPy.

  1. Decison Trees: Decision Tree classifier implemented from scratch in python. Dataset used: Banknote authentication dataset

  1. Support Vector Machine: A simple C-SVM binary classifier. Dataset used: Breast Cancer Wisconsin Dataset

  1. K-Means Clustering:

  1. Principal Component Analysis:
    • Dataset used: AT&T Database of Faces
    • Applied the Principal Component Analysis (PCA) algorithm for dimensionality reduction on face images.

  1. Moving Averages
    • Dataset used: Air Quality Data Set
    • Applied Simple Moving Average (SMA), Cumulative Moving Average (CMA), Weighted Moving Average (WMA), Exponentially Weighted Average (EWMA) on the dataset, all functions are written in NumPy.
  2. Convolutions

Authors: