Machine Learning and Artificial Intelligence applied to astronomy