Steps to approach a Machine Learning Project
By: Nken Allassan
Tags: Data, Machine Learning, Feature Engineering, Data Science

Starting a Machine Learning (ML) project from scratch is not easy especially when you’re a newbie. From my own experience here is a post about the different steps to build and kick-start such projects.

The idea of this post came from my friend Genelva, which I will like to thanks for asking me how can we start a ML project, considering a data set you have in your possesion. Well, here was my answer 😉 :

The Origin and nature of the data

Knowing where the data comes from could be a source of valuable insights to your ML model as it can give information on how the data has been splitted. Generally, raw data are splitted into 3 sets, training validation and testing set, considering that the validation set is obtained from the training set. The splitting of the training and testing data is not usually random, and most of the time follows the same distributions (even if it is not the case, the idea is to identify which distribution both the train and test set follows) this information can help you think about which patterns the two sets of data points follow. Moreover the nature of the data could help you choose a suitable model for the training (example time series data suit well with recurrent neural networks 😊)

Exploratory data Analysis (EDA) and data preprocessing

Most of the time physical phenomenom generate data which follows a normal distribution. The trick is that most of these data are collected either by humans or machines which can bring out sources of errors called outliers. Outliers are set of values which do not follow the same distribution or rules like normal values. EDA can help you identify this data points easily as they may affect your ML model in a bad way. But it is important to note that, outliers can also give some extra information to your model (for example a drastic drop of the temperature of an area could be as a result of a change in seasonality, not necessarily a wrong value). EDA can also help you identify skewness in the data which generally need to be normalized or standardized, usally done during the data preprocessing stage. Dealing with large values in ML can cause overfitting of your model. The reason been that, higher valued variables are much more prioritized than lower ones. To overcome this problem, it is important to draw back these values to a range suitable for training (generally between 0 and 1).

Feature Engineering

I like this part 😍. For me feature engineering is an art, the art of creating new and explicit features from already existing ones. Unfortunately this is where most data scientist give up! because it is time consuming and require alot of reflexion and intuition testing (a data scientist should be patient…generally I eat biscuit and drink milk when i enter into this critical thinking stage 😂😂). However it is worthy to do it !! since it boost the performance of your model.

Model Selection and Validation Strategy

Now you can select your model, this is the right time to do it. Generally most of us decide to choose a ML model before any analysis thinking that the best model will always win ….Nope! this is wrong (but as I said in the first point the nature of the data can give you an idea of which model to choose) . Talking of the validation strategy, your model should be able to fit well with unseen data, this is useful for the deployment phase of your project. Depending of the latter, I can mention K-Fold cross validation and Stratify fold validation. The efficiency of ML models are improved using this approaches in most cases.