Machine Learning and Cosmology