Skip to main content

What is Machine Learning ?

Overview: 

In this section we are going to learn about machine learning. In today's world, technology is evolving at its fastest pace so that even machines start to learn by themselves. Technology like artificial intelligence has proved to be good till today, but it is not guaranteed if it will be good by tomorrow. 

Concepts like NLP, machine learning, TensorFlow, data analytics, metaverse have given a new direction to the technical world and given a meaning to the statement that previous data can be useful for us.

what is machine learning?


Taking you forward, i am going to make you understand what exactly machine learning is and complete information about machine learning. 

In this topic we are going to learn: 

  • What is machine learning 

  • Types of machine learning

  • Importance of machine learning

  • Scope of machine learning

  • Future of machine learning

  • Machine learning vs deep learning vs artificial intelligence 


Before going to machine learning we should learn the following terms : 


Dataset: 

In machine learning, a dataset is a collection of data that is used to train, validate, and test models. The data in a dataset can include input data, output data (also known as labels), and other relevant information. The quality and quantity of the data in a dataset can have a significant impact on the performance of a machine learning model.

A dataset is always in the format of a table that is stored with .csv extension and other extensions etc. Don't worry if you don't get it, you will become more friendly while learning machine learning.

Dataset image

Fig: screenshot of a sample dataset.

There are several types of datasets in machine learning, including:

  • Training datasets: used to train models

  • Validation datasets: used to fine-tune the model's hyperparameters

  • Test datasets: used to evaluate the performance of a trained model

  • Unlabeled datasets: contains input data without output data, it is used in unsupervised learning

A dataset can be obtained from various sources such as CSV, Excel file, SQL databases, and APIs.

It's important to note that a good data set should be diverse, representative and large enough to train a robust model, and also it should be cleaned and preprocessed to remove any irrelevant or missing data.




What is machine learning?

The term machine learning was first introduced by Arthur Samuel in 1959.

 A basic definition: 

 “Machine learning (ML) is a type of artificial intelligence (AI) that allows software applications to become more accurate at predicting outcomes without being explicitly programmed to do so

 

Defining in more detail: 

“Machine learning is a type of artificial intelligence which is used to predict future output using previous data”. 

Application of machine learning: 

  • Recommendation systems: Machine learning are used in recommendation systems of you tube  , amazon and every big company is using it .

  • Email spamming can be detected by using machine learning . 

  • Healthcare: Predicting patient diagnostics for doctors to review

  • Social Network: Predicting certain match preferences on a dating website for better compatibility

  • Finance: Predicting fraudulent activity on a credit card

  • E-commerce: Predicting customer churn

  • Biology: Finding patterns in gene mutations that could represent cancer



To keep things simple, just know that machines “learn” by finding patterns in similar data. Think of data as information you acquire from the world. The more data given to a machine, the “smarter” it gets.


   “More data beats better models. Better data beats more data.” — Riley Newman


Machine “learns” really by using old data to get information about what's the most likelihood that will happen. If the old data looks a lot like the new data, then the things you can say about the old data will probably be relevant to the new data. It’s like looking back to look forward.


Types of machine learning 

Before learning the types of machines learning we should know what is labelled and unlabeled data. 
 Labelled data:  In machine learning, labeled data refers to a dataset that includes both input data and corresponding output data, where the output data is also known as labels. Labels are used to train and test models, allowing the model to make predictions on new, unseen data. The labeled data is used to train the model, and the labels are used to evaluate the performance of the model.
For instance, in a housing data set, the features might include the number of bedrooms, the number of bathrooms, and the age of the house, while the label might be the house’s price. in a spam detection dataset, the features might include the subject line, the sender, and the email message itself, while the label would probably be either “spam” or “not spam.”
In simple language, label is the column which contains result also. Labelled dataset is the dataset which contains result dataset also.


Talking about types of machine learning, it can be divided into four types : 

  • Unsupervised machine learning 

  • Supervised machine learning

  • semi -supervised learning

  • Reinforcement machine learning


Supervised machine learning further divided into two types : 

  • Regression 

  • Classification



Types of machine learning



Semi supervised machine learning is sometimes not considered as a type of machine learning. 



Supervised machine learning: 

Supervised machine learning is a type of machine learning where a model is trained on labeled data, which includes input data and corresponding output data or labels. The goal of supervised learning is to predict the output based on the input data. The most common types of supervised learning problems include classification and regression.

In classification problems, the goal is to predict a categorical label for the input data, such as classifying an email as spam or not spam. Examples of classification models include logistic regression, decision trees, and support vector machines.

In regression problems, the goal is to predict a continuous value for the input data, such as predicting the price of a house based on its square footage. Examples of regression models include linear regression, polynomial regression, and random forest.

Supervised learning models are trained using a dataset of labeled examples, and the model learns to make predictions by finding patterns or relationships between the input data and the corresponding labels. The model is then tested on a separate dataset to evaluate its performance.

Supervised learning is widely used in practice, for example, for spam detection, image classification, speech recognition, and natural language processing. It has a good performance in problems where labeled data is available, and it is a good starting point to gain insights from the data.


Unsupervised machine learning:



Machine learning is to find patterns or relationships in the data without any prior knowledge of the output. Some examples of unsupervised learning include clustering and dimensionality reduction.

In clustering, the goal is to group similar data points together. For example, clustering customers based on their purchasing behavior. Clustering algorithms like k-means and hierarchical clustering are commonly used.

In dimensionality reduction, the goal is to identify and remove redundant or irrelevant features in the data to reduce the complexity of the problem. For example, principal component analysis (PCA) which finds the most informative features and projects the data onto a lower-dimensional space.

Unsupervised learning has its own set of use cases, for example, in image compression, anomaly detection, and market segmentation. It's commonly used when labeled data is not available, or when the goal is to find hidden patterns or structures in the data without any prior knowledge of the outcome. It's also used as a pre-processing step to improve the performance of supervised learning models.


Reinforcement learning: 

This type of machine learning requires the use of a reward/penalty system. The goal is to reward the machine when it learns correctly and to penalize the machine when it learns incorrectly.
Reinforcement Machine Learning is a subset of Artificial Intelligence. With the wide range of possible answers from the data, the process of this type of learning is an iterative step. It continuously learns.

Examples of Reinforcement Learning:

  • Training a machine to learn how to play (Chess, Go)

  • Training a machine how to learn and play Super Mario by itself

  • Self-driving cars

 Semi supervised machine learning: 

Semi-supervised machine learning is a type of machine learning that combines both supervised and unsupervised learning. In this type of learning, the model is trained on a dataset that includes both labeled and unlabeled data. The goal is to use the unlabeled data to improve the performance of the supervised model by incorporating additional information from the unlabeled data.
One of the main advantages of semi-supervised learning is that it can make the most of limited labeled data, which is a common problem in many real-world applications. This is because it allows the model to learn from both labeled and unlabeled data, which can help to improve the model's performance and generalization.
Semi-supervised learning algorithms can be used for a variety of tasks such as classification, regression, and clustering. Some examples of semi-supervised learning algorithms include self-training, co-training, and multi-view learning.
Semi-supervised learning is a popular approach for many real-world applications, such as text classification, image classification, and speech recognition, where the labeled data is scarce or expensive to obtain.


Importance of machine learning : 

Machine learning is a rapidly growing field that has the potential to impact a wide range of industries and applications. Some of the key advantages of machine learning include:

  1. Automation: Machine learning algorithms can automate repetitive tasks and make predictions without human intervention.
  2. Scalability: Machine learning models can process and analyze large amounts of data, making them well-suited for big data applications.
  3. Improved Accuracy: Machine learning models can improve the accuracy of predictions and decision making, compared to traditional methods.
  4. Personalization: Machine learning can personalize experiences for individual users based on their behavior and preferences.
  5. Discovery: Machine learning can be used to discover patterns and insights in data that would be difficult or impossible for humans to uncover.
  6. Cost-effective: Machine learning can be cost-effective, as it reduces the need for human labor and increases efficiency.
  7. Predictive maintenance: Machine learning can be used to predict when a machine or equipment is likely to fail, allowing for proactive maintenance.


Machine learning vs Artificial intelligence vs Deep learning 

  
Relation between ai , ml , dl
 

Deep learning is a machine learning technique that is inspired by the way a human brain filters information, it is basically learning from examples. It helps a computer model to filter the input data through layers to predict and classify information. Since deep learning processes information in a similar manner as a human brain does, it is mostly used in applications that people generally do. It is the key technology behind driver-less cars, that enables them to recognize a stop sign and to distinguish between a pedestrian and lamp post. Most of the deep learning methods use neural network architectures, so they are often referred to as deep neural networks. 
Machine Learning is a subset of Artificial Intelligence that uses statistical learning algorithms to build systems that have the ability to automatically learn and improve from experiences without being explicitly programmed.

Future of machine learning: 

The future of machine learning is likely to involve continued advances in areas such as deep learning, reinforcement learning, and unsupervised learning, as well as the development of new techniques and approaches. Other areas of focus may include increased use of machine learning in industry and business, the creation of more robust and explainable models, and the integration of machine learning with other technologies such as natural language processing and computer vision. Additionally, there is likely to be a growing emphasis on ethical considerations in the development and deployment of machine learning models.

Comments

Popular posts from this blog

leetcode 48 solution

  48 .  Rotate Image You are given an  n x n  2D  matrix  representing an image, rotate the image by  90  degrees (clockwise). You have to rotate the image  in-place , which means you have to modify the input 2D matrix directly.  DO NOT  allocate another 2D matrix and do the rotation.   Example 1: Input: matrix = [[1,2,3],[4,5,6],[7,8,9]] Output: [[7,4,1],[8,5,2],[9,6,3]] Example 2: Input: matrix = [[5,1,9,11],[2,4,8,10],[13,3,6,7],[15,14,12,16]] Output: [[15,13,2,5],[14,3,4,1],[12,6,8,9],[16,7,10,11]]   Constraints: n == matrix.length == matrix[i].length 1 <= n <= 20 -1000 <= matrix[i][j] <= 1000 solution: class Solution { public:     void swap(int& a , int &b)     {         int c ;         c = a;         a = b;         b = c;     }     void transpose (vector<vector<int>...

2485. Find the Pivot Integer | Binary search

  Given a positive integer   n , find the   pivot integer   x   such that: The sum of all elements between  1  and  x  inclusively equals the sum of all elements between  x  and  n  inclusively. Return  the pivot integer  x . If no such integer exists, return  -1 . It is guaranteed that there will be at most one pivot index for the given input.   Example 1: Input: n = 8 Output: 6 Explanation: 6 is the pivot integer since: 1 + 2 + 3 + 4 + 5 + 6 = 6 + 7 + 8 = 21. Example 2: Input: n = 1 Output: 1 Explanation: 1 is the pivot integer since: 1 = 1. Example 3: Input: n = 4 Output: -1 Explanation: It can be proved that no such integer exist.   Constraints: 1 <= n <= 1000 Solution : class Solution { publ ic:     int pivotInteger( int n ) {         int sum = (( n )*( n + 1 ))/ 2 ;         int i = 1 ;         int j =...

Regular Expression Matching Leetcode Solution

Regular Expression Matching Given an input string s and a pattern p, implement regular expression matching with support for '.' and '*' where: '.' Matches any single character.​​​​ '*' Matches zero or more of the preceding element. The matching should cover the entire input string (not partial). Example 1: Input: s = "aa", p = "a"  Output: false  Explanation: "a" does not match the entire string "aa". Example 2: Input: s = "aa", p = "a*"  Output: true  Explanation: '*' means zero or more of the preceding element, 'a'. Therefore, by repeating 'a' once, it becomes "aa". Example 3: Input: s = "ab", p = ".*"  Output: true  Explanation: ".*" means "zero or more (*) of any character (.)". Constraints: 1 <= s.length <= 20 1 <= p.length <= 20 s contains only lowercase English letters. p contains only lowercase Englis...