cleaned up a bunch of code and updated the ML readme