scikit-learn is a production ready library that has some very well commented and easy to read source code.
https://github.com/eriklindernoren/ML-From-Scratch is an easy to understand understand implementation of some the basic ML algorithms built from first principles and aims for readability over performance.
https://github.com/eriklindernoren/ML-From-Scratch is an easy to understand understand implementation of some the basic ML algorithms built from first principles and aims for readability over performance.