[Machine Learning][Part 1]Supervised learning and unsupervised learning

Table of contents

Supervised Learning

Application 1: Data regression fitting

Application 2: Classification

Unsupervised Learning

The difference between supervised learning and unsupervised learning

practise:


Supervised Learning

         A model that learns through correct inputs and outputs. The input x and the correct output y are used as the training label.

Application 1: Data regression fitting

After the model completes training, it will perform data regression fitting on the training samples. When an x ​​is input that has never been input before, the model will update the fitting function and output the result.

        For example, to judge house prices, the training samples are the prices of houses with different areas in the past two years. The input x is the area and the output y is the house price. After the training is completed, the price of houses of various sizes can be predicted. Below are two data fitting methods: one is a curve, which is more accurate; the other is a straight line.

Application 2: Classification

Unlike application 1, where data regression prediction has many different outputs, classification has only two outputs: yes or no. For example, to determine whether a picture contains kittens, the output is: "There are kittens" and "There are no kittens".

Unsupervised Learning

Different from supervised learning, unsupervised learning does not need to specify y as the correct label to train the model. The model can divide the data in the sample set into different groups according to the characteristics of the sample set. Therefore unsupervised learning, only input x, no output y labeled as the correct result.

The main applications of unsupervised learning are: clustering algorithm (Clustering), anomaly detection (Anormaly detection), and dimensionality reduction (Dimensionality reduction)

The difference between supervised learning and unsupervised learning

As can be seen in the figure below, supervised learning on the left divides the data into correct and incorrect data, while on the right it just puts similar data together to form two different data sets.

practise:

Among the following four options, which ones are unsupervised learning algorithms (multiple choices):

Correct answer: options 2,3.

Option 1: To mark spam emails, you need to specify which emails are spam in the training set, so it is supervised learning

Option 2: Searching for news on the Internet does not specify which categories the news must be grouped into, so it is unsupervised learning.

Option 3: It does not specify which specific categories customers are to be divided into, so it is unsupervised learning

Option 4: Divide patients into two categories: those with diabetes and those without diabetes, so it is supervised learning and is a classification application in supervised learning.

Guess you like

Origin blog.csdn.net/x1987200567/article/details/132673553