Which means using linear machine learning models probably won’t model the real world very well.

This article will take a look at a non-linear data set, concentric circles, and see how we can apply a couple of machine learning and deep learning models to create a classification model.

There are many ways to approach this problem, and this article is not meant to be a complete body of work on the subject, but instead a more casual look at how to approach the problem.

DataSet

Image for post

scikit-learn: make_circles

The dataset was created with Scikit-Learns, make_circles, function. This creates a 2-class classification data which can clearly not be separated by a line. In this case we will need to add some non-linearity to our models.

First — lets see what happens when we try to use a linear model to separate this data.

LogisticRegression

Image for post

LogisticRegression

As you can see — LogisticRegression is only able to separate the data as best it can along a straight line. This model wont do.

LinearSVM

Lets look at a linear Support Vector Machine. Because this is also a linear model we would not expect it to perform any better. However we will also see that we can make Support Vector Machines perform very well.

#machine-learning #deep learning

There Are No Straight Lines In Nature
1.35 GEEK