Personal tools

ML Research and Applications

Different Machine Learning Models_010924A
[Different Machine Learning Models - Deepika Yadav]

 

Machine Learning:

Discovering the New Era of Intelligence

 

 

- Overview

Machine learning (ML) is complex, and how it works varies depending on the task and the algorithm used to accomplish it. However, at its core, a ML model is a computer that looks at datal and recognizes patterns, then uses those insights to better complete an assigned task. 

Any task that relies on a set of data points or rules can be automated using ML, even those that are more complex, such as responding to customer service calls and reviewing resumes. 

For example, let’s say a machine has to predict whether a customer will buy a specific product this year (e.g., “antivirus”). The machine does this by looking at the previous knowledge/past experience i.e. the data of the products the customer purchased every year, if he buys anti-virus software every year then there is a high chance that the customer will buy anti-virus software this year as well. 

This is how ML works on a basic conceptual level. If a machine's performance in a given task improves with experience, the machine is said to be learning certain classes of tasks from past experience (data input). 

The four main machine learning models are supervised learning, unsupervised learning, semi-supervised learning, and reinforcement learning.

Some applications of ML include: 

  • Image recognition
  • Speech recognition
  • Recommender systems
  • Fraud detection
  • Self driving cars
  • Medical diagnosis
  • Stock market trading
  • Virtual try on 

 

Please refer to the following for more details:  

 

- Machine Learning (ML) Today

Machine learning (ML) today is a data analysis method that automates the construction of analytical models. It is a branch of artificial intelligence (AI) based on the idea that systems can learn from data, recognize patterns and make decisions with minimal human intervention. While AI is the broad science of imitating human capabilities, ML is a specific subset of AI that trains machines how to learn.

ML is something that performs functions using the data fed to it and gradually gets better over time. ML and Statistics have a large overlap, as both fields study data analysis. But unlike statistics, researchers focus on the algorithmic complexity of ML and computational implementation. Part of ML research is the development of tractable approximate inference algorithms.

ML today is different from ML of the past due to new computing techniques. It was born out of pattern recognition and the theory that computers could learn without being programmed to perform specific tasks; researchers interested in AL wanted to see if computers could learn from data.

The iterative aspect of ML is important because ML models are able to adapt independently as they are exposed to new data. They learn from previous calculations to produce reliable, repeatable decisions and results. ML is not a new science, it's one that's gaining new momentum

 

- Machine Learning (ML) Techniques

The entire idea behind ML is to go from data to insight. From a given problem (by large business one) to an adequate solution. The ML algorithms help in predicting future trends, changes, and opportunities. However, large datasets are essential in this task. To harness them, data scientists use several ML techniques and methods.

Although the intention behind ML is to work without human assistance, to some extent, this assistance is indispensable. To put it in plain language, you have to teach your algorithm how it should work and what it ought to look for. This is exactly what the data scientists do. Does it sound familiar to you? It should! This is how humans learn–from experience. 

The ML algorithms use computational methods to “learn” information directly from available data. This is why it is crucial to input as much relevant data as it’s available. As the number of samples increases, the ML algorithm works more and more efficiently. 

ML is a type of machine intelligence that uses algorithms to learn from data and improve performance on a specific task. 

Some ML techniques include:

  • Supervised learning: Trains a model on known input and output data so that it can predict future outputs.
  • Unsupervised learning: Finds hidden patterns or intrinsic structures in input data.
  • Deep learning: A ML technique that focuses on hierarchical learning of representations, typically through neural networks.
  • Clustering: An unsupervised learning method that involves the grouping of data points.
  • Dimensionality reduction: A technique used in ML and data science to reduce the number of features or dimensions in a dataset.
  • Linear regression: A ML algorithm that attempts to model the linear relationship between one or more predictor variables and a continuous target variable.
  • Decision tree: A ML technique that involves using certain conditions or rules for the decision-making process
  • Ensemble methods: A ML technique that combines multiple base models/weak learners to create an optimal predictive model

 

- Supervised Learning – Task Driven (Predict Next Value)

Supervised Learning is the most popular paradigm for performing ML operations. It is widely used for data where there is a precise mapping between input-output data. The dataset, in this case, is labeled, meaning that the algorithm identifies the features explicitly and carries out predictions or classification accordingly. 

As the training period progresses, the algorithm is able to identify the relationships between the two variables such that we can predict a new outcome. Since supervised learning algorithms are focused on learning a specific task or prediction, they are often referred to as task-driven. 

Supervised learning lets you tackle two potential business problems: Classification. You need to segment your output data into specific categories. The algorithm will attempt to categorize the output data based on the input data. 

"Supervised learning - task driven" means that in ML, supervised learning is a method where the algorithm is specifically trained to perform a defined task by using labeled data, essentially teaching it to map input data to a known output, making it focused on achieving a particular goal rather than just discovering patterns in the data like unsupervised learning would do; hence, it's considered task-driven. 

Key characteristics about supervised learning:

  • Labeled data: The key aspect is that the training data is labeled, meaning each data point has a known correct answer associated with it, which guides the algorithm to learn the relationship between input features and the desired output.
  • Specific task focus: Unlike unsupervised learning, supervised learning aims to perform a specific task like classification (categorizing data) or regression (predicting continuous values) based on the labeled examples provided.
  • Example applications: Common examples of supervised learning include spam email filtering (classifying emails as spam or not spam), predicting housing prices based on features like size and location, or identifying handwritten digits from images.

 

- Unsupervised Learning – Data Driven (Identify Clusters)

In the case of unsupervised learning algorithm, the data is not explicitly labeled into different classes, that is, there are no labels. The model is able to learn from the data by finding implicit patterns. 

Unsupervised Learning algorithms identify the data based on their densities, structures, similar segments, and other similar features. Unsupervised Learning Algorithms are based on Hebbian Learning. 

Unsupervised learning is where you’ll hear most of the excitement when people talk about ‘the future of AI’ due to its limitless potential. It’s for example used for market segmentation (i.e. clustering groups of customers based on common characteristics) and to provide product recommendations based on a shopper’s historical purchase behavior. 

"Unsupervised learning - data driven (identify clusters)" refers to a ML technique where an algorithm analyzes unlabeled data to automatically group data points into distinct clusters based on their inherent similarities, without any prior knowledge of what the clusters should be, effectively revealing patterns and structures within the data itself. 

Key characteristics about unsupervised learning for cluster identification: 

  • No labeled data: Unlike supervised learning, there are no predefined categories or target values for the data; the algorithm must identify the clusters based solely on the data features.
  • Clustering algorithms: Common algorithms used for clustering include K-Means, Hierarchical Clustering, DBSCAN, and Gaussian Mixture Models, each with different strengths and suitability depending on the data distribution.
  • Goal: The primary goal is to find groups of data points that are closer to each other (based on a chosen distance metric) than to data points in other clusters. 

 

How it works:

  • Data preparation: The data is cleaned and standardized to ensure features are comparable and the algorithm can effectively calculate distances between data points.
  • Choosing a clustering algorithm: Depending on the data characteristics and desired outcome, an appropriate clustering algorithm is selected.
  • Clustering process: The algorithm iteratively assigns data points to clusters, usually by calculating distances to cluster centers (centroids) and adjusting the centroids until the clusters are optimized.


Applications of unsupervised learning for cluster identification:

  • Customer segmentation: Grouping customers based on their purchasing behavior to target marketing campaigns more effectively.
  • Image analysis: Identifying distinct objects within an image.
  • Anomaly detection: Identifying data points that deviate significantly from the identified clusters, potentially indicating outliers.
  • Gene expression analysis: Grouping genes based on similar expression patterns

 

- Reinforcement Learning – Learn from Mistakes

Reinforcement learning is a type of ML that processes information through trial and error, similar to how humans might approach a problem. Unlike other kinds of learning, such as supervised learning, reinforcement learning can happen without a human watching and responding to the interaction. 

Reinforcement Learning covers more area of AI which allows machines to interact with their dynamic environment in order to reach their goals. 

With this, machines and software agents are able to evaluate the ideal behavior in a specific context. With the help of this reward feedback, agents are able to learn the behavior and improve it in the longer run. This simple feedback reward is known as a reinforcement signal. 

The agent in the environment is required to take actions that are based on the current state. This type of learning is different from Supervised Learning in the sense that the training data in the former has output mapping provided such that the model is capable of learning the correct answer. Whereas, in the case of reinforcement learning, there is no answer key provided to the agent when they have to perform a particular task. 

When there is no training dataset, it learns from its own experience. The goal is find the best actions which maximize the long-term reward. The algorithm thus learns by trial and error. An example is learning to play a computer game by playing against an opponent.  

Reinforcement Learning (RL) is a type of ML where an artificial agent learns to make decisions by trying different actions in an environment, receiving feedback (rewards or penalties) for each action, and gradually adjusting its behavior to maximize the positive rewards, essentially "learning from its mistakes" through trial and error to achieve the best possible outcome in a given situation; similar to how humans learn through experience. 

Key characteristics about Reinforcement Learning (RL): 

  • Trial and Error: The core principle is learning through trial and error, where the agent takes actions, observes the results, and uses that feedback to refine its strategy.
  • Rewards and Punishments: The agent receives positive feedback (rewards) for actions that lead closer to the desired goal and negative feedback (punishments) for actions that move further away from the goal.
  • Autonomous Decision Making: Unlike supervised learning, RL agents can make decisions independently based on the environment they are in without explicit instructions.
  • Adaptability: RL allows agents to learn and adapt to changing environments, making it useful for complex situations with dynamic conditions.


Example scenarios where RL is used: 

  • Robot navigation: Teaching a robot to navigate a room by rewarding it for moving towards the desired destination and penalizing it for bumping into obstacles.
  • Game playing: Training an AI to play a video game by giving it rewards for winning levels and penalties for losing
  • Self-driving cars: Enabling a car to learn how to make optimal driving decisions in different traffic situations by providing feedback based on actions like lane keeping and braking


Data Scientist Roadmap_121824A
[Data Scientist Roadmap]

- ML Algorithms and Applications

While many ML algorithms have been around for a long time, the ability to automatically apply complex mathematical calculations to big data – over and over, faster and faster – is a recent development. 

In the last few years, we have witnessed a renaissance in ML and AI. AI broadly refers to the ability of machines to "think" like humans and perform tasks considered "smart," without explicitly being programmed to do so. 

ML is a subset of AI. ML algorithms build a mathematical model based on training data, and they leverage the model to make predictions when new data is provided. For example, a computer-vision ML model can be trained with millions of sample images that have been labeled by humans so that it can automatically classify objects in a new image. 

ML is about building intelligent artifacts, almost by necessity, typically, that learn over time based on experience. ML uses programming through neural networks. This is where ML “learns” through training algorithms and determines the probable outcome of a situation. The process requires a human to program the information into the ML with data, hours of training and testing and fixing issues in the outcomes. 

The important thing to remember with ML is that it can only output what is input based on the large sets of data it is given. It can only check from what knowledge it has been “taught.” If that information is not available, it cannot create an outcome on its own. Therefore ML will go for the solution whether or not it is the most optimal solution. 

As many people have wisely observed, the dream of ML is not new. It has been around since the very earliest days of computing. Pioneers have always imagined ways to build intelligent learning machines. ML is one of the most disruptive technologies of the 21st century. In the coming years, we are likely to see more advanced applications that stretch its capabilities to unimaginable levels. 

Examples of ML and DL are everywhere. It's how Netflix knows which show you’ll want to watch next, how Facebook knows whose face is in a photo, what makes self-driving cars a reality, and how a customer service representative will know if you'll be satisfied with their support before you even take a customer satisfaction survey. 

Key ML algorithms and their typical applications:

  • Linear Regression: Predicting continuous values like housing prices, sales forecasts.
  • Logistic Regression: Classifying binary outcomes like spam detection, disease diagnosis.
  • Support Vector Machine (SVM): Classification tasks with high accuracy, especially when dealing with complex datasets.
  • Naive Bayes: Text classification, identifying spam, classifying documents based on categories.
  • Decision Trees: Easy to interpret classification tasks, identifying key features.
  • Random Forest: Combining multiple decision trees for improved prediction accuracy.
  • K-Nearest Neighbors (KNN): Classification tasks where similar data points are grouped together.

 

- Important Considerations When Choosing An ML Algorithm

When selecting a ML algorithm, key considerations include: the type of problem you're trying to solve, the characteristics of your data (size, quality, distribution), desired accuracy level, computational resources available, interpretability needs, and the time constraints for training and prediction; essentially, balancing the best fit for your data with the practical requirements of your application. Following are Key factors to consider.

Data characteristics:

  • Data type: Is your data numerical, categorical, text, or a combination?
  • Data size: Do you have a large or small dataset?
  • Data distribution: Is your data normally distributed or skewed?
  • Feature dimensionality: How many features (variables) are present in your data?

Problem type:
  • Classification: Predicting a categorical outcome (e.g., spam/not spam)
  • Regression: Predicting a continuous value (e.g., house price)
  • Clustering: Grouping data points into similar clusters

Model complexity and interpretability:
  • Black-box models: High accuracy but difficult to understand decision-making process (e.g., deep neural networks)
  • Interpretable models: Easier to explain predictions, often preferred in high-stakes applications (e.g., linear regression, decision trees)

Performance metrics:
  • Accuracy: Proportion of correct predictions
  • Precision: Accuracy of positive predictions
  • Recall: Ability to identify all relevant cases
  • F1-score: Balance between precision and recall

Computational considerations: 
  • Training time: How long does it take to train the model on your data?
  • Prediction speed: How quickly can the model make predictions on new data?

Examples of algorithms and their suitability: 
  • Linear Regression: Good for simple relationships between features and target variable, interpretable
  • Logistic Regression: For binary classification problems, interpretable
  • Decision Trees: Can handle non-linear relationships, easy to visualize, good for feature importance analysis
  • Random Forests: Ensemble of decision trees, often performs well with high accuracy
  • K-Nearest Neighbors (KNN): Simple to implement, good for classification tasks with well-defined clusters
  • Support Vector Machines (SVM): Effective for high-dimensional data and complex classification problems
  • Neural Networks (Deep Learning): Powerful for complex patterns, but may require large datasets and computational resources

Important steps when choosing an ML algorithm:
  • Clearly define your problem: Understand what you want to predict and what metrics are most important
  • Explore your data: Analyze data quality, distribution, and feature relationships
  • Experiment with different algorithms: Try a variety of models and compare their performance on your data
  • Validate your model: Use cross-validation to assess generalization ability and avoid overfitting
  • Consider interpretability requirements: Choose an algorithm that allows you to explain the reasoning behind predictions if necessary

- Data Science and Machine Learning Models

Big data acts as an ingredient. Think of it as when you are making a cake – the data represents the flour and the actual process of baking the cake is represented through ML. AI will then be the output, or the cake if you will. 

Machine learning (ML) is a form of AI that enables a system to learn from data rather than through explicit programming. However, machine learning is not a simple process. As the algorithms ingest training data, it is then possible to produce more precise models based on that data. 

A ML model is the output generated when you train your machine-learning algorithm with data. After training, when you provide a model with an input, you will be given an output. For example, a predictive algorithm will create a predictive model. Then, when you provide the predictive model with data, you will receive a prediction based on the data that trained the model.

ML enables models to train on data sets before being deployed. Some ML models are online and continuous. This iterative process of online models leads to an improvement in the types of associations made between data elements. Due to their complexity and size, these patterns and associations could have easily been overlooked by human observation. 

After a model has been trained, it can be used in real time to learn from data. The improvements in accuracy are a result of the training process and automation that are part of machine learning.  

ML techniques are required to improve the accuracy of predictive models. Depending on the nature of the business problem being addressed, there are different approaches based on the type and volume of the data. 

 

- Machine Learning Models vs Data Science

Machine learning (ML) primarily focuses on building algorithms that enable computers to learn from data and make predictions. In contrast, data science has a broader focus that encompasses various techniques for extracting insights and meaning from data, including statistical analysis and data visualization. 

Data Science is a broad field that involves collecting, cleaning, analyzing, and interpreting large datasets to extract meaningful insights, while ML models are specific algorithms within Data Science that use data to learn patterns and make predictions without being explicitly programmed, essentially allowing computers to "learn" from data to perform tasks like classification or regression. 

Key differences to understand:

  • Data Science is a broader concept: It encompasses the entire process of data collection, cleaning, exploration, analysis, visualization, and interpretation to derive actionable insights.
  • Machine learning models are a specific tool within data science: They are algorithms designed to learn from data and make predictions based on patterns identified in that data.


Examples of ML Models used in data science:

  • Linear Regression: Predicting continuous values based on a linear relationship with input variables.
  • Logistic Regression: Predicting binary outcomes (like yes/no) based on input data
  • Decision Trees: Classifying data by making a series of decisions based on specific features
  • Random Forest: An ensemble of decision trees to improve prediction accuracy
  • Support Vector Machines (SVM): Classifying data by finding the optimal separation line between different classes

 

 


Document Actions