Ai Class 10
Ai Class 10
AI PROJECT CYCLE
PART-2
DATA EXPLORATION
DATA EXPLORATION THROUGH
VISUALIZATION
Objective - Know various data exploration techniques and its importance
Title: Data Exploration Approach: Activity
Summary: Students will explore different types of graphs used in
data visualization and will be able to find trends and patterns out of
it.
Learning Objectives:
1. Students will explore various types of graphical representations.
2. Students will learn how to visualize the data they have.
Learning Outcomes:
1. Recognize different types of graphs used in data visualization.
2. Exploring various patterns and trends out of the data explored.
Pre-requisites: Basic computer literacy
Key-concepts: Data Visualization
Data Exploration
The developer feeds in data along with some ground rules to the model. The model
gets trained with these inputs and gives out answers in the form of predictions. So,
the machine follows the developer’s rules or instructions and completes its job
properly.
The machine does not gain any learning experience. Ie. Static, it is only limited as
defined by the developer.
After looking through all the cases, we feed this data into the machine along with the
rules which tell the machine all the possibilities.
The machine trains on this data and now is ready to be tested. While testing the
machine, we tell the machine that Outlook Overcast; Temperature = Normal;
Humidity = Normal and Wind = Weak.
On the basis of this testing dataset, now the machine will be able to tell if the child can
go out to play golf or not and will display the prediction to us.
Rule based Approach
• suppose you have a dataset comprising of 100
images of apples and 100 images of bananas.
• To train your machine, you feed this data into the
machine and label each image as either apple or
banana.
• Now if you test the machine with the image of an
apple, it will compare the image with the trained data
and according to the labels of trained images, it will
identify the test image as an apple. This is known as
Rule based approach.
• The rules given to the machine in this example are
the labels given to the machine for each image in the
training dataset.
Rule Based A.I model
• Decision trees (most popular) follows a rule
based approach.
It is like an inverted tree with root on top and
leaves at the bottom, every component is known
as node
DECISION TREES
Following is a dataset comprising of 4 parameters (Outlook, Temperature,
Humidity and Wind ) which lead to the prediction of whether an Elephant
would be spotted or not.
Draw a Decision Tree for this dataset.
Learning Based Approach
Refers to the AI modelling where the model(program) can find
relationships/patterns and make decisions from a previously unseen
dataset (not defined by the developer). The machine learns by itself.
The A.l model gets trained to work on abstract, unstructured and
the random data fed to it and then is able to design a model which is
adaptive to the change in data and it figures out patterns and trends
out of it.
That is, if the model is trained with X type of data and the machine
designs the algorithm around it, the model would modify itself
according to the changes which occur in the data so that all the
exceptions are handled in this case.
Some definitions
• A machine learning Model - is a program that can
find patterns or make decisions from a previously
unsee
• A machine learning algorithm is a mathematical
method to find patterns in a set of data. Machine
Learning algorithms are often drawn from statistics,
calculus, and linear algebra. n dataset.
• The process of running a machine learning
algorithm on a dataset (called training data) and
optimizing the algorithm to find certain patterns or
outputs is called model training.
Learning Based Approach
• In other words, we can say that the dataset is known to the person who is
training the machine only then he/she is able to label the data.
• A label is some information which can be used as a tag for data. For
example, students get grades according to the marks they secure in
examinations. These grades are labels which categorise the students
according to their marks.
• Eg. You are learning python using manuals and online tutorials by following
the code examples. Supervised learning is where you learn python by
understanding its features by practicing the examples that act as labeled
data and then using the knowledge acquired to write python programs for
unseen use cases.
Applications of Supervised Learning
• Image classification: Identify objects, faces, and other
features in images.
• Natural language processing: Extract information
from text, such as sentiment, entities, and relationships.
• Speech recognition: Convert spoken language into
text.
• Predictive analytics: Predict outcomes, such as sales,
customer churn, and stock prices.
• Medical diagnosis: Detect diseases and other medical
conditions.
• Fraud detection: Identify fraudulent transactions.
• Email spam detection: Classify emails as spam or not
spam.
Advantages of Supervised Machine Learning
1. Classification
2. Regression
Classification: Where the data is classified according to the labelled
data. This model works on discrete dataset(represents a count
like total team members, population count, no. of moves in a
game etc. ) which means the data need not be continuous.
For example, in the grading system, students are classified on the
basis of the grades they obtain with respect to their marks in the
examination.
• Eating habits: Carnivorous, Herbivorous, Omni
• Seasons: summers, winters, spring, autumn
Regression:
• Regression: Such models work on continuous data. (are
measured like volume , weight, height, time, temp etc)
• For example, if you wish to predict your next salary, then
you would put in the data of your previous salary, any
increments, etc., and would train the model. Stock
exchange dataset, Real estate price prediction, Medical
insurance costs based on various factors etc. Here, the
data which has been fed to the machine is continuous.
Unsupervised Learning
An unsupervised learning model works on unlabelled
dataset. This means that the data which is fed to the
machine is random and there is a possibility that the
person who is training the model does not have any
information regarding it.
The unsupervised learning models are used to identify
relationships, patterns and trends out of the data
which is fed into it. It helps the user in understanding
what the data is about and what are the major features
identified by the machine in it.
It is of 2 types- Clustering and Dimensionality Reduction
Applications of Unsupervised Learning
• Clustering: Group similar data points into
clusters.
• Image segmentation: Segment images into
meaningful regions.
• customer segmentation, anomaly
detection, and data exploration.
Advantages of Unsupervised Machine Learning
• Now the machine has to learn on its own with new images of mixed
dogs and cats data set. It has to identify first which of the physical
characteristics of dogs are different from cat and group them based
on their attributes.
Supervised Learning Unsupervised Learning
Supervised learning algorithms are trained using labeled data. Unsupervised learning algorithms are trained using unlabeled
data.
Supervised learning model takes direct feedback to check if it is Unsupervised learning model does not take any feedback.
predicting correct output or not.
Supervised learning model predicts the output. Unsupervised learning model finds the hidden patterns in data.
In supervised learning, input data is provided to the model In unsupervised learning, only input data is provided to the
along with the output. model.
The goal of supervised learning is to train the model so that it The goal of unsupervised learning is to find the hidden patterns
can predict the output when it is given new data. and useful insights from the unknown dataset.
Supervised learning needs supervision to train the model. Unsupervised learning does not need any supervision to train
the model.
Supervised learning can be categorized Unsupervised Learning can be classified
in Classification and Regression problems. in Clustering and Associations problems.
Supervised learning can be used for those cases where we know Unsupervised learning can be used for those cases where we
the input as well as corresponding outputs. have only input data and no corresponding output data.
Supervised learning model produces an accurate result. Unsupervised learning model may give less accurate result as
compared to supervised learning.
Supervised learning is not close to true Artificial intelligence as Unsupervised learning is more close to the true Artificial
in this, we first train the model for each data, and then only it Intelligence as it learns similarly as a child learns daily routine
can predict the correct output. things by his experiences.
It includes various algorithms such as Linear Regression, It includes various algorithms such as Clustering, KNN, and
Logistic Regression, Support Vector Machine, Multi-class Apriori algorithm.
Classification, Decision tree, Bayesian Logic, etc.
In supervised learning training data is used to infer model In unsupervised learning training data is not used.
Optical Character Recognition Find a face in an image.
Less Computational Complexity More Computational Complex
Dimensionality Reduction
Dimensionality Reduction: We humans are able to visualise upto 3-Dimensions
only but according to a lot of theories and algorithms, there are various
entities which exist beyond 3-Dimensions. For example, in Natural language
Processing, the words are considered to be N-Dimensional entities. Which
means that we cannot visualise them as they exist beyond our visualisation
ability. Hence, to make sense out of it, we need to reduce their dimensions.
Here, dimensionality reduction algorithm is used.
As we reduce the dimension of an entity, the information which it contains starts getting
distorted. For example, if we have a ball in our hand, it is 3-Dimensions right now. But if
we click its picture, the data transforms to 2-D as an image is a 2-Dimensional entity. Now,
as soon as we reduce one dimension, at least 50% of the information is lost as now we will
not know about the back of the ball. Whether the ball was of same colour at the back or
not? Or was it just a hemisphere? If we reduce the dimensions further, more and more
information will get lost.
Hence, to reduce the dimensions and still be able to make sense out of the data, we use
Dimensionality Reduction.
Dimensionality Reduction
Reinforcement Learning (RL)
• Reinforcement learning is a machine learning training method based on
rewarding desired behaviors and/or punishing undesired ones.
• is a learning method that interacts with the environment by producing actions
and discovering errors Trial, error, and delay are the most relevant
characteristics of reinforcement learning. In this technique, the model keeps on
increasing its performance using Reward Feedback to learn the behavior or
pattern.
• It is about learning the optimal behavior in an environment to obtain maximum
reward. This optimal behavior is learned through interactions with the
environment and observations of how it responds, similar to children
exploring the world around them and learning the actions that help them
achieve a goal.
• In the absence of a supervisor, the learner must independently discover the
sequence of actions that maximize the reward. This discovery process is
akin to a trial-and-error search.
• The principle of reinforcement suggests that when we follow behavior
with pleasant consequences, that behavior is likely to be repeated.
Additionally, behavior followed by unpleasant consequences may be less
likely to be repeated.
• Activity : Teachable machine to demonstrate
Supervised Learning
https://teachablemachine.withgoogl e.com/
● Activity : Infinite Drum Machine to
demonstrate Unsupervised learning
https://experiments.withgoogle.com /ai/drum-
machine/view/
Evaluation