Machine Learning ( ML) is an important sub-field in Artificial Intelligence and It is referred to as a combination of two disciplines Data Science and Software Engineering. The main focus of Machine Learning is creating algorithms and statistical models.
In this article, we will learn about
- Core concepts of Machine Learning (ML) model,
- Different kinds of Machine Learning (ML) models
Reference: Microsoft Official Page Fundamentals of machine learning – Training | Microsoft Learn
What is Machine Learning (ML)?
Machine learning allows computers to learn from historical data, detect patterns in the data using algorithms, and make decisions or predictions accordingly.
Types of Machine Learning
- Supervised Learning
- Unsupervised Learning
- Reinforcement learning
Some of the examples are
- The proprietor predicts ice cream sales on a particular day based on weather forecasts using sales history and weather records.
- Doctors use various patients’ histories to find new patients at risk of diabetes using factors such as weight, blood glucose, etc.
- Researchers use previous records to identify penguin species based on flippers, bills, and other attributes
Training & Prediction
The Machine Learning model uses a function to calculate output based on the different inputs. This process of defining the function known as training and predicting new values is referred to as inferencing.
Steps involved in training
- Trained models include observations with attributes x, usually a vector such as x1, x2, or x3.
- The value to be predicted is the label referred to as y.
Consider the examples
- In ice cream sales, weather measurements such as temperature, wind speed, and rainfall are the features (x) and the number of ice creams sold is the label (y).
- The patient’s measurements such as weight, and blood glucose level are features and the risk of diabetes is referred to as label (1-at risk, 0-not at risk).
- In the identification of penguin species, the measurement of the length of its flippers, and bill width are features, and species is the label. (0-Adelie, 1-Gentoo, 2-Chinstrap)
- An algorithm is used to determine the relationship between features and the label. The basic principle is to fit function to data, in which label is predicted based on features.
- The algorithm result is the model that encapsulates calculation as a function. the mathematical notation is given as y=f(x).
- We must check trained models with the different sets of features (x)and predict labels based on features using the function. The label is given as “y-hat”.
Types Of Machine Learning (ML)
Supervised Machine Learning (ML)
Supervised Machine Learning determines the relationship between features and labels in past observations to train the model and predicts the new label for different features.
Regression
This form of Supervised Machine Learning predicts a label of type numeric value. Some of the examples are
- Number of icecreams sold based on various weather factors
- The selling price of a property varies based on size, number of rooms, etc.
- A car’s fuel efficiency depends on weight, width, height, and engine size.
Classification
Classification is the form of a Supervised model in which the label represents a category or class. The two common classifications are
- Binary Classification and
- Multiclass Classification
Binary Classification
The binary classification model predicts one of the two mutually exclusive outcomes.
Examples
- Predicts whether a patient is at risk or not based on clinical metrics
- Whether a bank customer will seek a loan or not based on credit history.
- What will be the response (positive or negative) of a customer about a marketing offer based on past purchases
The prediction output will be anyone among true/false or positive/negative for a single class.
Multiclass Classification
It extends binary classification and predicts the mutually exclusive labels, which means one among the multiple possible labels.
For example
- The penguin species(Adelie, Gentoo, or Chinstrap) is based on its physical measurements.
- The Movie genre (comedy, horror, romance, adventure, or science fiction) is based on cast, director, and budget.
Certain algorithms are available to train this multiclass model which can provide more labels for a single observation, for example(a movie, can come under the category of comedy and science fiction).
Unsupervised Machine Learning (ML)
The unsupervised ML model involves training data with only features but without known labels and its algorithms determine relationships between the features in the data.
Clustering
Clustering is a form of unsupervised machine learning. The clustering algorithms determine similarities between observations based on features and group them into discrete clusters.
Example:
- Group similar flowers based on petals, leaves, and size.
- Based on purchase history groups similar customers.
It is similar to multiclass classification in categorizing into discrete groups. The only difference is that in multiclass classification, the class is already known so it determines the relationship between the features and the known label. In clustering there is no previously known label so it groups based on the similarity of features.
The clustering is useful to determine the class before training, for example
- To segment customers
- Analyze groups and identify and categorize customers.
- Label based on categorization.
- Train using labeled data and predict the category of new customers.
Conclusion
This article mainly deals with the fundamentals of Machine Learning (ML) and its types such as Supervised Machine Learning and Unsupervised Learning. In the upcoming posts, we will learn about each form of Machine Learning (ML) such as regression, classification, and clustering in detail with examples.
Check my other article about AI Fundamentals