Machine Learning by example

Motivation

This project was born when my Big Data course taught by Karim Pichara at the Pontificia Universidad Catolica in Chile ended. During the course, we had programmed a few models and I thought that it would be interesting to take some time to clean the code and make it available to everyone. Indeed, I found that implementing/reading the code of the models we studied was very helpful to develop a better understanding of the laters.

My main goal is not to provide a stand alone course but simple implementations of famous models with visual elements to help understand the concepts. I also tried to add some tips to facilitate the understanding of the maths behind. This means that a basic idea of how the models work might be required. I will try to add links to the ressources that helped me during this first step as much as possible.

Please be aware that these are very simple implementations not meant to be used in production (was not tested for dimensions other than the ones of the datasets, was not unittested ...). If you are looking for a robust library, go check scikit learn for instance.

If you see any bug/error or would like to contribute/improve. Please send a pull request. If you have any question or would like to comment, please use the github issue system.

Organization of the code

  • src folder: gathers the code and the notebooks
    • fct.py: gathers general functions that are needed in some or all of the notebooks (such as normalizing functions).
    • notebooks: one for each model
  • datasets folder: contains all the used dataset. The name are pretty explicit.
  • requirements.txt: to be installed. Please note that the notebook was only tested with Python v3.4.2 and the version of the librairies specified in the requirements file.

Models

Dimensionality reduction

Supervised Learning

Unsupervised Learning

Reinforcement Learning

Todo

  • add Q-Learning
  • add SARSA
  • add Gaussian Process

LICENSE

FreeBSD, cf to the LICENSE.txt file.