Module 2:
AI ML and DL Data Mining methods for Healthcare
CO2:Apply Advanced AI algorithms for Healthcare Problems
Content:
• Knowledge discovery and Data Mining, Multi classifier Decision Fusion:
Ensemble Learning, Meta-Learning and other Abstract Methods
• Evolutionary Algorithms, Illustrative Medical Application-Multiagent
Infectious Disease Propagation and Outbreak Prediction, Automated
Amblyopia Screening System etc.
• Computational Intelligence Techniques, Deep Learning, Unsupervised
learning, dimensionality reduction algorithms.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Knowledge Discovery in Healthcare (Pattern finding)
• Knowledge Discovery in Databases (KDD) may be defined as the process
of finding potentially useful patterns of information & Relationships in
data.
• Healthcare organizations are storing large amounts of data about patients
and their Medical conditions.
• As the quantity of clinical data has accumulated, Domain Experts using
Manual Analysis has failed, as data is increasing continuously.
• Data visualization techniques can assist in the Manual Analysis of data,
but if an organization having large DB can receive hundreds or even
thousands of matches to a simple Query which is impossible for human
to differentiate.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• In health care, pattern recognition has long been linked with
expertise Example: Radiologist can read X-Ray.
• Data mining is a set of methods that attempts to uncover patterns
that are difficult to detect with traditional statistical methods.
• Patterns are evaluated/tested for how accurate they hold on unseen
cases.
• Databases, data warehouses, and data repositories are becoming
very common, but specialized skills are required to find hidden
pattern in data.
• Machine based Innovative discovery-based approaches to health
care data analysis are required, as there are situations where human
are not able to search hidden patterns.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• Detection of "outliers“ in a pattern over large data sets by
classification, or clustering using statistical modeling is easy
compared to Manual Analysis.
• Medical data may be clinical (disease related) data and non-clinical
(medicine related) data which is stored in Datawarehouse.
• Medical data has a lot of information buried within it, so by using
Data Mining, new pattern can be discovered thus providing new
medical knowledge.
• Problem is most medical DB are unstructured in nature so data
manipulation becomes challenging.
• Computational and theoretical problems exist while performing data
modeling in high-dimensional spaces with this massive amounts of
data.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• Data mining takes clinical analysis one-step further by automating the
process of discovering patterns or knowledge in a data warehouse.
• For example: Instead of the user asking for a report of patients with
heart failure , he can ask system what are signs of fatal heart failure
so prevention can be taken.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Advance classification Algorithms.
• Multi classifier decision fusion is a technique in which it is assumed all
classification algorithm are equally experienced over the entire feature
space so their opinion must be taking in decision making.
• Here basic idea is instead of depending on one classifier for pattern
recognition we can have multiple classifier, all well trained on data set
and final decision will depend on max voting. This concept is called as
Ensemble learning.
Decision fusion
method includes
Majority Voting
method or
Weighted Voting
method
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Ensemble Leaning/Model
• An ensemble model combines a series of k Learned models (or base
classifiers) i.e M1, M2, : : : , Mk, with the aim of creating an improved
composite classification model i.e M*.
• A given data set (D) is split into k different training sets (D1, D2,D3,
….., Dk). Here each splitted dataset is given to a classifier(Mi) for class
prediction.
• The ensemble returns a final class prediction, considering class
prediction given by majority base classifiers .
• There can be same classifier for different dataset or different
classifier for different data set.
• An ensemble tends to be more accurate than its base classifiers.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Ensemble Modelling
• The base classifiers may make mistakes, but the ensemble model will
misclassify ,only if half of the base classifiers gives wrong prediction.
• Ensembles yield better results when there is significant diversity
among the models i.e prediction given by base classifiers differ to
large extent.
• Each base classifier (Mi) can be allocated to a different CPU and so
ensemble model prediction is faster as it get advantage of parallel
processing.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
M*
Composite
Model
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Ensemble Model Algorithms/Techniques
•Bagging: Example is Random Forest ( Parallel
Processing )
•Bosting: Example is Adaptive bosting (
Sequential Processing )
•Stacking: A metamodel based approach
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Bias V/S Variance
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Random Forest Algorithm
• Here each of the classifiers in the ensemble learning is a decision tree
classifier so that the collection of classifiers is a “forest.”
• Data set D is sampled with replacement (Bootstrap Sampling) in 2 ways.
A) Row Sampling, Here subset of record is given to each Decision Tree
classifier
B) Column Sampling/Feature sampling, Here subset of features is given to
each classifier.
• Each Base Decision Tree classifier, get trained and gives its prediction so
final outcomes is based on majority voting in case of classification and it
will be average value in case of regression.
• Decision Tree are base learners which have Low Bias(training error) and
High variance(testing error) i.e OVERFIT MODEL
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• But when decision given be all base classifiers is combined, high
variance get converted to low variance.
• Since we are giving different set of training set to each base classifier,
each model will get trained properly resulting in low bias.
• A small change in training data will not make that much change in
accuracy of base learning models as changed data will randomly get
distributed between all base learners so overall effect of change in
data sample is very small.
• DIFFERENCE BETWEEN BAGGING ALGORITHM(BA) & RANDOM
FOREST(RF) IS RF DO ROW N COLUMN SAPLING BOTH BUT BA DO
ONLY ROW SAMPLING
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Boosting (Adaptive Boosting)
• In boosting, weights are assigned to each training tuple. A series of k
classifiers is trained on dataset one by one.
• After a classifier, M1 , is trained, it will be tested on each training tuple and
then weights are updated to allow the next classifier, to “pay more
attention” to the training tuples that were misclassified by M1 .
• Now M2 i.e next classifier will be trained on tuples misclassified by M1 this
will ensure that M2 learns to classified tuples misclassified previously.
• This process repeats till all k classifiers completes its training in above
mentioned way.
• The final boosted classifier, M*, combines the votes of each individual
classifier, to do prediction, here classifier after iteration is boosted i.e
moving from weak learner to strong learner.
• This boosting technique will have low variance and bias will decrease after
every iteration.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Ada Boosting (Adaptive Boosting)
• AdaBoost (short for Adaptive Boosting) is a popular boosting
algorithm using only Decision Tree classifier.
• Algorithm:-
1. Assign equal weight to each tuple as (1/N) where N is number of
tuple
2. Create Stump( Decision Tree with 1 level ) and calculate Gini
Index(Entropy/Information Loss) of every independent column.
NOTE: COLUMN WITH MIN GINI INDEX WILL BE SELECTED FOR
CONSTRUCTION DECISSION TREEE
3. Select Stump with lowest gini index and calculate its total error [TE]
4. Calculate Performance of that Stump as (PS)= ½ loge [ (1-TE)/TE]
5. Update weight of every tuple :
i. Tuple correctly classified = Old weight * e^-PS ( decrease weight )
ii. Tuple wrongly classified = Old weight * e^ PS ( Increase weight )
6. Normalize weight of every tuple by diving each weight with Σ W
7. Define a Range for every tuple considering interval as its own
weight
8. Run Iteration equal to number of tuples to build new data set from
existing data set, here record misclassified will be getting more
importance compared to tuples correctly classified.
9. For this new data set repeat step 2 to 8 till all base models are
trained.
10. To do prediction, give tuple to each of the base model and consider
Majority voting to do final prediction.
3. Stacking: It is an ensemble learning technique where the predictions
of multiple base models are used as input to a meta-model, which then
makes the final prediction.
K-fold Sampling Meta Model
Serial + Parallel combined
• Here dataset is divided into 2 parts namely DTRAIN & DTEST.( 80:20)
• If total tuples are 1000 then DTRAIN=800 & DTEST=200
• We again divide Dtrain into two parts let it be Dtain=600 and
Dvalidate=200.
• Suppose we have 3 base model (SVM, LR, DT ) all these will be trained
on 600 dataset and predicted on 200 remaining dataset.
• Now we have total 600 predicted values and these 600 predicted and
actual value will be dataset for Meta_Model ( Random Forest)
• Then Meta_Model will be tested on Dtest for its accuracy.
• Stacking model is combination of Parallel + Serial Processing
Meta learning
• Meta-learning, also known as “learning to learn” is a type of Artificial
Intelligence (AI) that focuses on creating models that can learn how
to learn.
• Here instead of learning from data we learn from output generated
from Machine Learning Model i.e Model learns from Meta Data.
• Meta Deta refers to Output/Prediction/Patterns generated from Base
Models.
Meta Leaning
means Stacking
learning from uses Meta-
learned data Learning
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• Meta-learning algorithms typically involve training a model on a variety of
different tasks, with the goal of learning generalizable knowledge that can
be transferred to new tasks.
• Meta-learning is a type of machine learning that is focused on using output
of trained model to learn new things.
• It trains the developing algorithm so that it can solve new problems with
minimal human intervention and in minimum time. So, it is popularly known
as “learning to learn algorithm”
• Meta-Learning learns from the output of this previously trained algorithm
by analyzing their data.
• Learning algorithms learn from historical data and make predictions when
given new examples of data.
• Meta-learning algorithms make predictions by taking the output from
existing machine learning algorithms as input and predicting a number or
class label.
• Meta-learning occurs one level above machine learning.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• The meta-classifier learns from mapping between predictions made
by previous classifiers and actual value of the data .
• Meta leanings results in better accuracy, let us understand using real
life example
• Suppose a teacher want to know who are defaulter students in
his/her class one way will be observe their attendance till 2 weeks
this type of learning can be called as machine learning.
• But instead of observing attendance for two week, teacher can ask
previous SEM teachers about defaulter students in class. This method
will give faster result and this type of learning os called Meta
Learning.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Other learning method to improve accuracy
How to train models if there is limited dataset available ?
Transfer Learning: Here we transfer knowledge of one domain into
another domain
How do we achieve this ??
We use pretrained model like VGG16, RESNET, INCEPTION V3,
MobileNet etc.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Evolutionary Algorithms(EA)
• An evolutionary algorithm is an AI-based computer application that
solves problems by employing processes that mimic the behaviors of
living things.
• It uses mechanisms that are typically associated with biological
evolution, such as reproduction, mutation and recombination.
Advantages:-
• Increased flexibility: Evolutionary algorithm can be adapted to solve the
most complex problems humans face and meet target objectives.
• Better optimization: The vast “population” of all possible solutions is
taken into consideration. This means the algorithm is not restricted to a
particular solution.
• Unlimited solutions: Unlike classical methods that present and attempt
to maintain a single best solution, evolutionary algorithms include and
can present multiple potential solutions to a problem.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• The collection of individuals on which the evolutionary algorithm
operates is called the “population.”
• The population is a set of genotypes (i.e unique sequence of DNA)
where multiple copies of the same genotype are present.
• The possible solution we get on genotype mutation is called as
phenotypes ( observable genotype example height, weight etc)
• It is important to note that the phenotype space is often very
different from genotype space
• The entire evolutionary process occurs in the genotype space.
• The final solution is the phenotype that is obtained from decoding the
fittest genotype after the termination condition.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• In EA we select two best fit genotype and mutate it to generate a new
genotype.
• The new individuals/children thus formed have their fitness
evaluated to compete for survival in the next generation.
• We test performance of this new Genotype by decoding it into
phenotype.
• After certain number of iteration, 80% worst solutions of the initial
random population are substituted by the best offspring children
filtered after survival selection process based on the evaluated fitness
value.
• These newly created offspring provide optimum solutions hence we
say Genetic Algorithms are used to solve optimization problems.
• This process continues till we get our desired phenotype/optimum
solution
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Genetic Algorithms
• Genetic algorithms are a special case of the more general class of
evolutionary algorithms .
• Genetic algorithms are the most widely known type of evolutionary
algorithm.
• The primary construct that distinguishes genetic algorithms from
other evolutionary algorithm variations is the representation of the
candidate solutions/populations.
• The representation of an individual in a genetic algorithm is defined
as a string over a limited alphabet.
• Various applications fit this representation and general optimization
strategy, including automated drug design, sequence alignment,
molecular structure/folding/docking optimization, and general
computational biology.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Assignment 02:
LEFT RIGHT
Q1. Multiagent Infectious Q1. Automated Amblyopia
Disease Propagation and (Lazy Eye) Screening System
Outbreak Prediction
Q2. Anticancer Drug Design
Q2. Genetic Sequence and High-Throughput Screening
Classification
Reference book:AIH by Arvin Agah , page no 45 to 48
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Computational Intelligence
• Computational intelligence is a group of computational models and
tools devoted to solution of problems for which there are no effective
mathematical or analytical approach.
• It is a sub-branch of AI and it is adaptive(keep changing) in nature
• It focuses on heuristic algorithms such as Fuzzy, Genetic Algorithms,
and Artificial Neural Network(ANN).
• It is also called as soft computing as results generated here has
uncertainty and are approximate i.e unprecise solution
• Some of most widely used techniques for computational intelligence
are Neural networks, Fuzzy systems. Genetic Algorithm, Swam
intelligence, Artificial Immune System(AIS).
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
1. Neural Network.
• Neural networks here refer to artificial neural networks (ANNs).
• They are developed to emulate biological neural systems. The basic
building blocks of biological neural systems are neurons.
• We have MP model, Perceptron Model, Multilayer Perceptron Model,
Back Propagation all these are called ANN.
• When the have large number of neuron arranged
in multiple layers its called Deep Neural Network.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• Relative ease of training ANNs for classification purposes has led to
many applications of ANNs in medicine.
• One of the most popularareas has been cancer diagnosis and
prognosis.
• ANNs have been applied to skin cancer diagnosis, breast cancer
diagnosis, breast cancer prognosis, lung cancer diagnosis, lung cancer
prognosis/recovery, bladder cancer prognosis, prostate cancer
treatment, brain cancer diagnosis and ovarian cancer diagnosis.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
2. Fuzzy System.
• In the real world there exists knowledge which is vague, imprecise,
uncertain, ambiguous, inexact, or probabilistic in nature.
• Humans can take decision in such situation because of their thinking and
reasoning ability as they can corelate similar situation.
• Example:- Human can corelate speed of Mixer-Grinder/Washing-Machine
by observing speed of Fan. i.e 450 rpm means machine is slow
• The computing systems, based upon classical set theory and two-valued
logic(i.e Boolean logic), cannot answer questions like tall, short, cold, hot
etc as human does, because they do not have completely true answers.
• Example: 450 rpm is slow speed, fast speed or mid-speed binary machines
cannot resolve as they only understand TRUE/ON/1 and FALSE/OFF/0.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• This concept was introduced by Lotfi Zadeh in 1965, which is an
extension of classical set theory, in fuzzy set elements have degrees
of membership i.e αA.
• In classical sets theory , sets are defined by a simple statement
describing whether an element having a certain property belongs to a
particular set or not.
• Example:
• U= {1,2,3,4,5} & A={1,2} then αA(1) = αA(2) =1 but αA(3) = αA(4) =
αA(5) =0
Thus, in classical set theory αA(x) i.e Membership of element x in SET A,
has only the values 0 ('false') and 1 ('true''). Such sets are called crisp
sets.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• For Non-crisp sets the characteristic function αA(1) can be defined.
using membership function and such Non-crisp sets are called Fuzzy
Sets.
• The number μA(x) represent degree of membership of x in A.
Example:-
U = {1,2,3,4,5,6,7,8,9,10,11,13} i.e set of natural number <=13
Find
A= Set of “Small prime” numbers from U it will be
Fuzzy set of A ={ (2,1),(3,0.8),(5,0.6),(7,0.4),(11,0.2),(13,0.0)}, which is
of the form (x,y) here “x” represent Element and “y” represents its
membership value(μA(x) )
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Fuzzy Clustering: Same as K
mean clustering but here
every point has a cluter
membership i.e Point P
belong to cluster C1 with
membership 0.7 and cluster
C2 with membership 0.2 and
cluster C3 with membership
0.1
A fuzzy controller is a type of
control system that uses fuzzy
logic to handle imprecise, vague,
or uncertain information. Unlike
traditional control systems that
Membership functions of fuzzy sets low, medium, and high with use precise mathematical models,
regard to temperature. fuzzy controllers operate based
on rules and linguistic variables
that mimic human reasoning.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• Fuzzy clustering is used to categorize medical image like MRI,
CT-SCAN. Example an MRI image is tumor with membership 0.7 while
its not tumor with membership 0.3.
• Fuzzy control has been widely applied to the anesthesia control
problem. Various fuzzy controllers have been introduced to control
the volume and timing of anesthesia infusion based on vital signals
inputs from the patient
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
3. Genetic Algorithm(GA)
• GA belongs to a general class of methods called evolutionary
computing, which is based on the concept of natural evolution
• It simulate biological phenomena such as population, natural
selection, genetic inheritance, mutation, survival of the fittest, and so
forth, usually in a stochastic manner, to perform a guided random
search.
• GA is a metaheuristic algorithm that is used to provide useful
solutions for optimization problems
• GA is an iterative algorithm that keeps a list of good solutions—the
population. In each iteration, new solutions are generated from the
current population and evaluated using a fitness function
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• A problem is described in GA by an appropriate fitness function and
chromosome/genotype. The purpose of the fitness function is to
evaluate desirability of each solution. This is important in selecting
solutions that should be kept or used to generate new solutions
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• One area of GA applications is genetic research. GAs have been
applied to selection, mapping, profiling, and classification of genetic
data and DNA microarray. DNA information is stored in String Array
and then its is mutated with other String Array to create new DNA.
• In cancer diagnosis problems, medical images are the diagnostic
inputs, and GA is used to extract the appropriate image features that
can be used to detect the existence of cancerous cells, while the
fitness function is usually the percentage of correct classifications.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
DEEP LEARNING & Unsupervised Learning
[ SELF STUDY ]
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
4. Swam Intelligence
• Swarm intelligence models the social behavior of organisms living in swarms or colonies
like ants,fish and bird.
• One ant follow other to walk in same line or bird/fish maintain a particular distance and
shape while they fly/swim (coordination)
• It is a form of agent-based modeling aiming at collective behavior of intelligent agents
in decentralized and self-organized systems.
• A swarm intelligence system typically consists of a population of simple agents
(individuals) interacting locally with one another and with their environment.
• These agents follow simple rules without centralized control dictating how individuals
should behave.
• Local interactions of agent-to-agent or agent-to-environment lead to the emergence of
intelligent global behavior or pattern which is unknown to the individual agents.
• ROBOTS uses these technique to accomplish their task
• Suppose you leave 5 Robots to clean your room how they will coordinate with each
other ?
• So swam intelligence is collaborative behavior in decentralized environment.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
PSO (Particle Swam Optimization)
• The Particle Swarm Optimization (PSO) algorithm is a
population-based optimization technique inspired by the social
behavior of birds flocking or fish schooling.
• It was developed by James Kennedy and Russell Eberhart in 1995. :
Term Used:-
• Particles: The individual elements in the swarm representing
potential solutions.
• Swarm: A collection of particles.
• Position: The current location of a particle in the search space.
• Velocity: The rate of change of the particle’s position.
• Personal Best (pBest): The best position a particle has achieved so
far.
• Global Best (gBest): The best position found by the entire swarm.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Algorithm:-
Step 1: Initialization: Initialize a swarm of particles with random positions
and velocities in the search space. & Evaluate the fitness of each particle
based on the objective function.
Step 2:Update Velocity: For each particle, update its velocity based on its
current velocity, the distance from its personal best position (pBest), and the
distance from the global best position
Step3:Update Position :Update the particle’s personal best position using
the updated velocity
Step4:Evaluate: Evaluate the fitness of each particle in its new position.&
Update the particle’s personal best position if the new position is better.&
Update the global best position if any particle's new position is the best
found so far.
Step 4:Loop:Repeat the update steps until a stopping criterion is met (e.g., a
maximum number of iterations or a satisfactory fitness level).
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Advantages
• Simple Implementation: The PSO algorithm is relatively easy to
implement and understand.
• Few Parameters: It requires the tuning of only a few parameters.
• Effective: It can find good solutions with less computational effort
compared to other optimization algorithms like Genetic Algorithms
(GAs).
Drawback:-Slow convergence in the refined search stage
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
5. Artificial Immune System (AIS)
• AIS model works similar to our human immune system. The human
immune system is a robust, decentralized, error-tolerant, and
adaptive system.
• The main function of the human immune system (Antibodies) is to
search for malfunctioning cells from its own body such as cancer cells
and foreign disease-causing elements such as bacteria and
viruses(Antigens).
• These foreign elements recognized by the Human Immune
System(HIS) are referred to as Antigens.
• Human body produces Antibodies to fight against Antigen.
• Different algorithms mimic this similar behavior and properties
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
AIS algorithm are are used in
1. Protecting Static File
2. Protecting Network
3. Protecting Process
END
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Key Terms in AIS
• Immune Memory: Similar to the biological immune system, AIS can "remember"
past encounters and use this memory to recognize and respond to known
threats more efficiently.
• Clonal Selection: This principle involves the selection and cloning of the most
effective antibodies (solutions) to respond to specific antigens (problems).
• Negative Selection: This mechanism is used to ensure that the immune system
does not attack the body's own cells. In AIS, this can be applied to anomaly
detection by distinguishing between normal and abnormal patterns.
• Immune Network Theory: This theory suggests that the immune system is a
network of interacting antibodies and antigens, which helps in maintaining
homeostasis and recognizing patterns.
• Danger Theory: This concept proposes that the immune system responds to
signals indicating danger or damage rather than simply recognizing foreign
entities. In AIS, this can be applied to detect and respond to potential threats in
a system.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Example: Negative Selection Algorithm
• It works similar to body immune system by absorbing all
foreign/external particles present in our body which are responsible
for infection, while its does not absorb particles which don’t harm our
body.
Working:-
STEP 1:Define Self Set: Collect a set of normal data patterns (self set).
These patterns represent the normal behavior of the system.
STEP 2:Generate Candidate Detectors: Randomly generate a set of
candidate detectors. These detectors are potential/danger patterns
that could match non-self data.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
STEP 3:Negative Selection: Compare each candidate detector against
the self set, If a candidate detector matches any self pattern, it is
discarded. If a candidate detector does not match any self pattern, it is
kept as a valid detector.
STEP 4:Apply Detectors: Use the valid detectors to monitor new data:If
a detector matches a new data pattern, the pattern is classified as
non-self (anomalous).If no detectors match the new data pattern, the
pattern is classified as self (normal).
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Dimension Reduction Algorithms
• Dimensionality reduction algorithms or DRAs reduce the number of
dimensions that exist within a dataset.
• Suppose your data set consist of N features/column out of which only
K columns are useful for ML algorithm so here (N-K) column are
discarded but we require some algorithm to do this and these
algorithms are called as Dimension Reduction Algorithms.
Example:-
Here we can
drop 3 & 5
column as they
are less
important in
price prediction
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
• Medical health records contain a wealth of information, but only some
information is relevant in predicting disease risk or illness progression. What data
is relevant to understanding future risk of disease or adverse event?
• Dimensionality reduction refers to converting a dataset of many dimensions into
fewer dimensions while concisely representing similar data.
• Dimension reduction is extremely useful in machine learning tasks and have
benefits like:
[Link] dimensions result in quicker computations when compared to the original
dataset.
2. By default, dimension reduction algorithms reduce the space required for
storage.
3. Reducing data into less than three dimensions enables visualization and easier
understanding.
4. Redundant data is removed, which improves the performance of the machine
learning model.
5. Noise is removed, which improves model performance.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
Ways to achieve this:-
1. Missing/Null Values:
• Missing data and null values are not a huge problem in large data set, but a
growing number of empty values may help determine whether to drop a
variable, ignore missing values, or compute a predicted value.
• Most data scientists support the dropping of variables if an attribute has
upward of 50% empty or null values.
[Link] Variance:
• Data attributes that are very similar to one another do not carry much
information.
• We can calculate variance between them and if variance is low we can drop
one of them
• As variance is dependent on range, data normalization should take place
first before calculating variance
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
3. High Corelation:
• Attributes with similar data trends are likely to carry similar information.
• Multicollinearity is the carrying of similar information that can reduce the
performance of the model so we can drop such features.
4. Information Gain/ Entropy in Ensemble Learning:
• We can calculate Information Gain to decide features which can be
dropped inn classification problems.
5. Backward Feature Elimination:
• In this the model trains on n attributes in first Iteration then on n-1
attributes in 2nd Iteration and so on
• The dropped attribute which shows the smallest increase in error rate is
used to decide column/ features to be dropped.
• This test is very Expensive due to high computational cost.
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)
6. Forward Feature Construction:
• Forward Feature Construction is the opposite of Backward Feature
Elimination.
• The model starts with one attribute and evaluates which of the
attributes has the highest increase in performance.
• Attribute which does not contribute much in performance increase
can be reduced.
7. Principal Component Analysis (PCA)
• Principal component analysis decreases the number of variables
(axes) through transforming an original set of variables into a new set
• It used mathematics such as standardization, covariance,
eigenvectors and eigenvalues to reduce N dimension into K
Dimension there will be some loss of accuracy in this process but
computation will be faster
BY Prof. Ichhanshu Jaiswal (VCET,VASAI)