Building the machine learning model