10th Part B-Unit 2 AI Project Cycle-1

Download as pdf or txt
Download as pdf or txt
You are on page 1of 17

Kendriya Vidyalaya No.

2 Raipur
Vocational SkillPart B
UNIT II (AI Project Cycle)

In this Unit :

 Introduction to AI project cycle  Understanding problem Scoping


 Simplifying Data Acquisition  Data exploration with data visualization
 Modelling  Neural Network
 Evaluation

 Introduction to AI project Cycle:


AI is making computer think & act like humans.
AI technology have entered in our lives in the form of various devices & applications. Behind this technology
a major role is played by the AI project Cycle.
AI Project Cycle refers, to clearly defines different stages from scratch to AI complete project to achieve
defined project objective in specified time schedule.

AI Project Cycle in Brief:


1. Problem Scoping: The first step of AI project cycle is to identify the problematic area which needs a
solution. The project outlines the challenges of the system & briefly describes the areas where AI can serve
as a solution.(Aim & Scope of the project undertaken is decided)
2. Data Acquisition: The Steps to collect & prepare all of the relevant data for use in machine learning. The
data is collected to ensure that the system operates in a proper manner. (acquiring relevant data)
3. Data Exploration: The Data is collected should be arranged in a proper manner for better understanding.
The analysis of the data can be done only if it is arranged in a systematic manner. (clear & normalized
data)
4. Modeling: It is a process in machine language which can be done either manually or automated by
selecting which specific machine learning algorithm we can use in building a model. (select best
algorithm for the model)
5. Evaluation: Finally Evaluation of the machine learning project is done. The more accurate is the result of
your model, the easier it will be to meet the requirement of the stakeholder. (Testing phase)

Figure of AI Project Cycle

1
A.I Part B - Unit 2 of class10 AI Project Cycle
Why do we need AI Project Cycle?
The AI project cycle is all about how to convert a real life problem or a challenges into a computer based
AI model. The AI model works on the problem solving area & collects the data required for solving the
problem. The data collected is then arranged in systematic order & then based on the collected data
modeling technique is decided & later evaluation is done.

 Understanding problem Scoping:


Problem Scoping is to focus on the problem for which we are aiming. The main element of, problem scoping is
in itself a skill where you need to focused on the relevant details related to the problem.
The first step of AI project cycle is choosing a “Theme &Topic ”.
Under Problem Scoping, First you have to choose the Theme & Topic of AI project.

So Theme of our AI project will be “Population” & title “Traffic Issues”

Theme Title List of problems

According to the traffic, timing


of signal should increase or
POPULATION TRAFFIC ISSUES decreace
(THEME) (TITLE)
Difficult to identify the crowd
of traffic

Goal for our AI project will be:

To place a Multiple sensor on the road side at a certain distance & AI camera at top of the road
to get exact data, so that we can manipulate the time of the signal according to the traffic.

Setting a goal is not enough, in order to solve the problem, the problem statement must be clearly defined.
How this problem is affecting & to whom, What is the cause &why should it be solved. For this we have to be clearly
about 4W’s Canvas

4W’s Canvas is a tool for problem framing method that helps in describing & interpreting a problem to arrive at a
problem statement. 4W’s Canvas tool is also known as “Problem statement template”.

The4W’s Canvas is a tool to explore a problem


Space in term of WHO, WHAT, WHERE, & WHY
And formulate a problem statement with clarity.

2
A.I Part B - Unit 2 of class10 AI Project Cycle
Who: This block help in finding the people who are getting affected directly or indirectly due to the problem, they are
also known as stakeholders.
What:This block is used for finding the kind of problem we are facing, i.e. nature of the problem.
Where: This block help in to look into the situation in which the problem or context or location of the problem.
Why: This block thinks about the benefit of the stakeholders as well as the society from the solution.

Who What Where Why


Are Affected directly or What is a problem & how Context / Situation / Benefits of the
indirectly by the problem do you know that it is a Location of the problem. stakeholders as well as
i.e. stakeholders problem. The evidence is society.
found to prove that this is
a real problem & must be
solve.

Stakeholders are the people who face the problem & would be benefited with the solution.

 Simplifying Data Acquisition


(Acquiring/ gathering or collecting relevant data for our project is known as DATA ACQUISITION)
In this stage data required for the project is acquired in specific forms & format, in order to work upon &
produce outcome, correct data in right form must be fed in AI project.
Data Acquisition refers to understanding, gathering, filtering & cleaning data as per the
requirement of the AI system so as to train it using the collected data.

To build AI system, you need to source a large amount of data & create data set for training, testing &
evaluation.

What is data?
Data can be defined as a reprenstation of facts or instruction about some entity. Data is collection of facts,
numbers, words, picture, audio, video, map etc. Data can be numeric & alpha-numeric.

3
A.I Part B - Unit 2 of class10 AI Project Cycle
DATA: A single entity, information or fact is known as data.

DATA SET: A set of collection of data, in a tabular form is known as data set.

THE ACQUIRED DATA CAN BE OF TWO TYPE:

1. Unstructured Data: It is a data that is not organized to any pre-existing data model. Unstructured data is
unprocessed data. Example, The data we got from social media post.
2. Structured Data:It is a data that has purposely designed, pre-defined structure as per some existing data
model. Example, the above table, students detail datable is known as structured data.

QULITY OF DATA WE HAVE ACQUIRED MUST BE:

1. ACCURATE:Correct & accurate data i.e. real data (dummy data will not be entertained)should be collected.
2. RELEVANCE: It means, the relevant data. Data that is necessary for the AI project.
3. RELIABLE:Is the data collected from reliable source & authentic source.
4. TIMELINESS:Up-to-data the data should be collected means latest data should be used in AI project.
5. VALIDITY:Data should relate & correct data should be used for the goal of the project.
6. COMPLETENESS:Comprehensive, valid & complete data should be used.

DATA ACQUISITION:
Data Acquisition begins, when you acquire data in quality form

For acquiring the data, we need a reliable data source, they can:

1. Interview: Refers to one-to-one conversation between an analyst and the user & client to find out about the
system, its functions & flaws.
2. Survey:Refers to a study of the opinion, response, etc. of a group of stakeholders.
3. Observation:Method refers to human or mechanical watching, noticing or perceiving of what people actually
do or what event take place in a specific working environment.
4. API (Application Programming Interface):It refers to interface that work behind the popular software
program or game to collect specific type of data of user.
5. Web Scraping:Web data extraction is data scraping used for extracting data from website. It refers to data
collection technique using a tool called web scraping that extract data from websites.
6. Sensors:They are mini devices that can collect data bout an environment or a body of a specific task.

4
A.I Part B - Unit 2 of class10 AI Project Cycle
7. Camera’s:It is a way to collect data graphically or in video form about the look, design o action as per the
requirement.
8. Internet:We can get data directly from government web site from internet that data what we collect from the
government website will be authentic &genuine data for the goal of our project. (Government website can be
in the form of data.gov.in, india-gov.in, censusindia.gov.in).

From 100% data we acquire for our AI project goal

80% of it is used in Training the AI Machine. (i.e. is known as Training Data)


During data Acquisition feeding previous data into a machine is called Training Data.
20% is used to test the AI Machine (i.e. known as Test Data)
At the time of testing, these data are used to find the AI algorithm is working correctly of not.

 Data Exploration with Data Visualization


Data Exploration means exploring the data with an intention of understanding the nature of data.
Data Exploration is a process of arranging the collected data in to a form which can be analyzed or through
which we can derived useful information.

The data we acquired from the different sources is to visualized with the help of graph so that, the data can be
understood easily in short period of time.
Data Visualization refers to the process of representing data visually or graphically by using visual
element like charts, graphs, diagram, & maps etc.
Data Visualization is a power full technique to represent the big data in the form of graphics.

Different ways to visualize the data are:Data can be visualized using


1. Charts: These use an established pattern or theme for displaying data. They are visual method to represent
data.
2. Graphs:These containa X & Y axis, with at least one showing numerical data.
3. Maps:These are used for visualizing geospatial, geographical data.
4. Temporal:These display the data over a period of time, with a start & a finish time.
5. Network:These demonstrate how data is related within a network
6. Infographics:These visually display textual data in a multiple of aesthetically pleasing way.

5
A.I Part B - Unit 2 of class10 AI Project Cycle
Let us now see different visual technique in detail with respect to above table:
1. Bubble Chart:It is primarily used to depict & show relationship between numeric variables with size as
additional dimension, bigger marker means bigger value.
50

40
Series1
30
Series2
20
Series3
10
Series4

-5 10 15
-10

2. Line Graph:It shows trend in data at equal interval. Line charts are useful for predicting the changes in a value
over a period of time. 45
40
35
30
25
20
15 Maths
10
AI
MALE

MALE

MALE

MALE

MALE

MALE

FEMALE

MALE

FEMALE

FEMALE
English
Hindi
Science
XA XB XC XA XD XD XA XB XC XB

9 10

3. Pie Graph:It shows the proportional size of item that make up a single data series o the sum of the item.

Over all performave in all subject


1 Anam X A MALE
5% Naman X B MALE
6% 12%
Rahul X C MALE
9%
13% 4 Anshu X A MALE

10% 5 Bhau X D MALE


9% Balit X D MALE
9% Bhumi X A FEMALE
13%
14% Bhim X B MALE
Dipali X C FEMALE

6
A.I Part B - Unit 2 of class10 AI Project Cycle
4. Bar Graph:A bar cart illustrate comparison among individual items mainly of number type. This is use in
a single dataset to compare the values.

XA XB XC XA XD XD XA XB XC XB
10
FEMALE

m n ul hu u t mi m ali j
Ana ma Rah Ans Bha Bali Bhu Bhi Dip Anu
FEMALE

9
MALE
8
FEMALE
7

MALE
6

MALE Series1
5

MALE
4

MALE
3

Na

MALE
2

MALE
1

10 20 30 40 50
5. Histogram:It is used to summarize discrete or continuous data by showing the number of data point that
fall within a specified range of values (called Bins)
The only difference between bar graph & histogram is there is gap between every data in bar graph but in
histogram continuous graph is used.

6. Heat Map:It is a graphical representation of data in


which values are represented by colors.
A graphical heat map represents area of high temperature
& low temperature.

7
A.I Part B - Unit 2 of class10 AI Project Cycle
7. Node Link Diagram:It shows how thing is interconnected through the use of nodes/vertices an lines to
represent their connection & the type of relationship between the group of entity.

8. Word Cloud:Data visualization technique represents the frequency of a word within a body of the text
with its relative size in the cloud. It is used on unstructured data as a way to display high-or-low frequency
word.

Benefits of data visualization are:

1. Better Analysis
2. Identifying patterns
3. Exploring business insights.

8
A.I Part B - Unit 2 of class10 AI Project Cycle
 Modeling
Modeling a phase during which the AI model for the desires outcome is trained using the collected data
repeatedly until it starts producing the desired result.
Modeling (developing & training an AI) refers to mathematically analyzing the data & its
insider relationship & with the parameter passed, & finding way through algorithm &repeted training to
reach the desired result or outcome.
The ability to mathematically describe the relationship between data & parameter from the core of every AI
model.

There are mainly two types of AI model or there are two category of AI model, they are:
1. Learning Based AI Model
2. Rule Based AI Model
Machine Learning

Learning Based AI
Model

AI Models Deep Learning

Rule Based AI Model

Rule Base AI Model :Also known as “Model driven AI Model” refers to branch of AI where models
are developed using the algorithm having pre-defined labels, rules, pattern & relationship.

The rule based AI is used when we have known or labelled dataset.

Rule based model are often preferred for limited scale project that require limited effort, cost & update.
In other words the rule based systems are not largely scalable.

Drawback of Rule based AI model are:

Although Rule base AI model are easier to maintain & implement, they suffer from the following
drawback:

1. Lots of manual work.


2. Consumes a lot of time.
3. Suitable only for less complex domains.
4. Limited adaptability & learning capacity.
5. Static & not scalable.

9
A.I Part B - Unit 2 of class10 AI Project Cycle
Learning Base AI Model
Also known as data-driven AI model, it is a system in which a lots of data is shown & question / Answer
are asked in order to train the system about the right answer.

The learning based AI model refers to branch of AI where models are trained to learn byinputting them lots of
data. Here, there are no patterns, rules & relationships predefined by the developer, rather machine learns
which each input & comes up with own algorithm.

Thelearning bases approach is used when data is unknown or random or labelled.

Under Learning Based AI model, “Machine Learning & Deep Learning” falls.

 Machine Learning: It is a branch of AI that enables machine to automatically learn & improves at
tasks with experience & by the use of data.
ML can automatically learn & improve without explicit being programmed.
The recommendation system on music & video streaming services are example of ML

 Deep Learning:It is a subset of ML where learning takes place through example. Deep learning
computer-nodes filter the input data using the layer & rue-based algorithm to predict & classify
information.
Task like speech & Image recognition are performed through deep learning system. Self-Driving
car isdevelop using deep learning.

Learning Based Approaches are:


1. Supervised Learning: It is a machine learning approach, where the machine use to learn with
the help of algorithm (the model) learns on the labelled dataset & is later tested with some
unlabeled data whose answer are pre-known to evaluate its accuracy on training data.

Advantage of Supervised Learning:


a) Computationally less complex.
b) It is high accuracy & trustworthy method.
c) It is very useful in case when user has an exact idea about the class of project.
d) It woks even better & optimally when the user has some prior experience with similar cases.

10
A.I Part B - Unit 2 of class10 AI Project Cycle
Disadvantage of Supervised Learning:
a) Computation time is very high for supervised learning.
b) Pre-labeled data set is to be feed in the AI model of desired result.
c) Continuous updating is required in it.

Example, of real life there supervised learning is used are:


a) Bio-Metric Identification
b) Speech Recognition
c) Spam Detection
d) Objet-Recognition for vision.

2. Unsupervised Learning:In it there is no supervision/ no feedback/ no pre-know/ desired


output & not even any labeled data.
Unsupervised machine learning discovered patterns within an existing set of unlabeled data, i.e. the
data without having an pre-existing labels or categories. Unsupervised learning based AI model find
pattern, trends & feature & club the data having same pattern in one group of cluster.
Unsupervised learning approach works with unlabeled data & creates cluster of item having
similar feature, characteristics or pattern.

Advantage of Unsupervised Learning:


a) It is very useful in finding all kind of known patterns & feature in data.
b) As it work with unlabeled data, it makes it very useful in real-life situation where labelling
of data is not feasible.
c) The training of model takes place in real-time.

Disadvantage of Unsupervised Learning:


a) Time taking
b) Getting an accurate result will take time.
c) More & more dataset is to be input for the desired & accurate result.

11
A.I Part B - Unit 2 of class10 AI Project Cycle
3. Reinforcement Learning: Means something that strengthens or encourage something.
The reinforcement learning approach is exactly the same, that we use to teach the small baby or
kids, such that is they do good thins then they are appreciated & if they do anything wrong they are
scolded or the same work is to be done again until got the desired result.
In reinforcement Learning approach, AI model (the algorithm, is also known as agent),
continuously doing the same task until & unless get the desired output or result.
In reinforcement learning algorithm relies on:
1. The learning from past feedback
2. Long term strategy keeping in mind the final goal & best possible reward.

Advantage of Reinforcement Learning:


a) It focus on a problem as a whole.
b) It does not need a spate data collection set.
c) It can work easily in unknown environment set.
d) It is very use full in solving very complex problem.

Disadvantage of Reinforcement Learning:


a) It is not suitable for simple problem.
b) Requires heavy-dataset.
c) Too much reinforcement learning may hamper exploration which can weaken the result.
d) It may take more time than expected.
Unsupervised Learning Supervised Learning
1. It is a type of ML that happens 1. It is a type of ML that happens
without human supervision. A under human supervision.
machine try’s to find the patter itself.
2. Unlabeled dataset 2.Labeled dataset is required
3. Model is given only input values & 3.Model requires labeled input dataset
no corresponded output data. on the basis of it output is generated.
4.The output result can be predicted 4.Output result is known in it.
5.May provide less accurate result 5.It provide accurate result.

12
A.I Part B - Unit 2 of class10 AI Project Cycle
 Evaluation
Evaluation in general term, refers to evaluating a system or device in a systematic way to check its merit,
correctness & performance as per a set of standards.
Evaluation refers to systematically checking & analyzing the merit, correctness & reliability of
AI model based on the output produces by it.

Once a model has been made & trained, it needs to go through proper testing so that one can calculate the
efficiency & performance of the model. Each & every model is tested with the help of testing data
(Which is separated out of acquired dataset) & the efficiency of model is evaluated on different parameters.
Evaluation is done with the help of testing data not with training data.

Why Evaluation is important:


Evaluation is crucial for any AI model to succeed in real world application. As the aim of an AI model to
produce result for any unknown new data, based on its learning evaluation ensures that it is truly happening.
Evaluation checks & ensures an AI model for:
1. If an AI model is producing result because of its learning or memorization.
2. If an AI model is operating correctly & optimally.

The cause behind performance of AI model:


1. Overfitting: Refers to a situation when an AI model performs so well as the test data is got, fitted exactly
against its training data & thus AI model always produce correct result.
2. Underfitting: Refers to when AI model is not complex enough to capture the structure & relationship of
its training data & predict effective outcome.
3. Generalization:Refers to how well the concept learned by a machine learning model applies to specific
example not seen by the model when it was learning. The goal of good ML model is to generalize well from
the training data to any data from the problem.
Ideally, an AI model should be balanced between underfitting& overfitting to be a good fitting.

Model Evaluation Metrics:


Metrics refers to a system or standard of measurement used to assess something, In the world of AI, metricsis
to test & evaluate a developed AI model to asses if it is accurate & efficient enough.
There are different types of metric used to assess the AI model based on these parameters, (Classification
Metrics) they are
1. Confusion Metrix
2. Accuracy
3. Precision
4. Recall
5. F1-Score

13
A.I Part B - Unit 2 of class10 AI Project Cycle
1. Confusion Metrics: It is a technique using a chart of table for summarizing the performance of a classification
based AI model by listing the predicted values of an AI model & the actual/correct outcome values.
A confusion table incudes both predictive & actual values in context of AI model.
Actual Value represents actual result (observed or measured)
Actual Value

True False
Predictive Values represent the value of the outcome/result of the AI model, produced on the basis of
algorithm & learning.
Predictive Values

Positive Negative
Before we proceed to how to create & use confusion metrics, it is important to know some keyword, they are:
1. True Positive (TP): True Positive refers to an instance for which bot predicted value for the AI model &
actual value are positive. Ex. Lady Finger is vegetable.
2. True Negative (TN): True Negative refers to an instance for which both predicted value of AI model &
actual value are negative. Ex. Lady’s Finger is not vegetable.
3. False Positive (FP): (Also called Type I error) It refers to an instance for which predictive value ao an AI
model is positive but actual value is negative.
4. False Negative (FN): (Also called Type II error) It refers to an instance for which predicted value of AI
model is negative but the actual value is positive.

Reality (True/False)
Actual Value
N=TP+FP+FN+TN True (Positive) False (Negative)

Positive No. of True Positive (TP) No. of False Positive (FP)


Prediction (Type I Error)
Negative No. of False Negative (FN) No. of True Negative (TN)
(Type II Error)

Note: When Reality = Prediction then True


When Reality ≠ Prediction then False

Using the confusion metrics, you need to computer the following value to evaluate an AI model:

1) Accuracy Rate: This is the percentage of times the prediction out of all the observation are correct.

Correct prediction
Accuracy = X 100 %
Total cases

Number of correct prediction (TP+TN)


Accuracy= -------------------------------------------------------------------------- X 100%
Total Number of prediction made (TP+TN+FP+FN)

14
A.I Part B - Unit 2 of class10 AI Project Cycle
2) Precision Rate:This is the rate at which the desirable prediction turn out to be correct. (True Positive
out of all positives)
TP
Precision= ----------------------- X 100%
(TP+FP)
3) Recall:It is a rate of correct positive prediction to the overall number of positive instance in the dataset.

Prediction actually positive TP


Recall = ------------------------------------------- = --------------------X 100%
Actual Positive values in the dataset (TP+FP)

4) F1 Score: (F-Measure)It is measure of balance between precision & recall. When Avoiding both false
positive & false negative, is equally important for our problem.
TP
F1 Score = -------------------------------
TP+ (FP+FN) / 2

Que. For an AI model developed to check if a painting is authentic or not its confusion matrix is
given below (0 means False & 1 means True)

Actual Value Predictive Values


N=192 Predictive 0 Predictive 1
Actual 0 118 12
Actual 1 47 15

15
A.I Part B - Unit 2 of class10 AI Project Cycle
 Neural Network:
It is same as ML in which AI machine learn anything by itself with the help of CV or data feed in it.
A major contribution to this AI is through Artificial Neural Network (ANN), which can learn on their own&
increase & update their knowledge with time & experience.

Biological Neural Network:


Our brain has a large number ( " 1011) of high connected element ( " 10 4connection per element) called
Neurons. Neurons have three major components:
1. Soma:It is cell body that contains nucleus, & sums & thresholds all incoming signals.
2. Axon:The Axon is a long fiber that carries signal form the cell body out to other neurons.
3. Numerous Dendrites: they are tree like receptive network of nerve fibers that carry electrical signal into
cell body.
Along with these three components listed above an important role is played by synapse.
Synapse is the pint of contract between an axon of one cell & a dendrite of another cell is called synapse.

ARTIFICIAL NEURAL NETWORK (ANN)


ANN is a software or circuit-based simulation of a biological neural network. ANN refers to collection of
connected computation unit or nodes (called neurons) along with biological inspired computer program designed
to simulate the way in which natural network of human brain process information.
Message transferred from a neurons are called action potential.
ANN is dived into multiple layers (Input layer, Hidden layer & output layer), each layer of an ANN consists
of several artificial neurons called nodes. Each neurons nodes has to perform a specific ask & passes the
information to the next layers.

Neurons equivalent of neurons (called node)


Weighted Input Equivalent to dendrites.
Activation Function Equivalent to soma
Synapse Connection from a neuron to another that carry the information.
Axon Output

Structure of ANN
A neural network is divided into multiple layers. Each layer of an ANN consists of several artificial neurons
Called nodes. Each node has to perform a specific task & pass the information to next layer.

16
A.I Part B - Unit 2 of class10 AI Project Cycle
1) Input Layer: This is the first layer of a neural network is called the input layer, whose role is to acquire data &
fee it to neural network. It just takes the input data & passes it on the next connected layer.
2) Hidden Layer: Input layer is connected with hidden layer 1, which further connected to another hidden layer 2
or to an outer layer.

The role of hidden layer is to process the input data & carry out the task.

3) Output Layer: After processed data travel through multiple hidden layer, it finally fed to the final layer
known as output layer.

Training ANN is not so complex task, commonly used is supervised learning.

Feature of Neural Network:


1. Neural Network have been developed to mimic the structure & working of human brain.
2. Neural Network can work with big data set.
3. Neural Network evolve & automatically learn with each input & each new attempt.
4. ANN takes ample time to train & need lots of data to train.

Application of ANN:
1) Character recognition:It is a process of recognizing the text inside image & converting it into an
electronic form. These image could be of handwritten text, printed text like documents, receipts etc.
2) Speech Recognition:Siri, Alexa & google Assistance are example of it.
3) Computer Vision:AI can accurately understand & process visual data effectively like videos & images.
4) Image compression:Neural Network can receive & process vast amount of information at once,
making them useful in image compression. It means storing & processing the data with less amount of
data.
5) Pattern Recognition:Neural Network also very useful in recognizing of patterns. Patterns are basically
repeated trends in various forms of data.

17
A.I Part B - Unit 2 of class10 AI Project Cycle

You might also like