際際滷

際際滷Share a Scribd company logo
Genetic Algorithms
George Bora
UTCN
December 4, 2013
George Bora (UTCN) Genetic Algorithms December 4, 2013 1 / 20
Computer Science to Evolutionary Computation
Within the vast 鍖eld of computer science under its vast array of potential
applications there exists the branch of arti鍖cial intelligence.
George Bora (UTCN) Genetic Algorithms December 4, 2013 2 / 20
Computer Science to Evolutionary Computation
Within the vast 鍖eld of computer science under its vast array of potential
applications there exists the branch of arti鍖cial intelligence.
One of the sub-branches of arti鍖cial intelligence is evolutionary
computation which seeks to achieve continuous optimization and
combinatorial optimization by incorporating knowledge of natural evolution
processes.
George Bora (UTCN) Genetic Algorithms December 4, 2013 2 / 20
Basic Concepts from Biology
The basic building blocks for evolutionary computation, which have kept
their names from their native science, are as follows:
genes
allele
chromosome
individual
mapping
mutation and crossover
鍖tness function
George Bora (UTCN) Genetic Algorithms December 4, 2013 3 / 20
Genes
The element from which this method derives it name, as genes are the
basic building blocks of life.
George Bora (UTCN) Genetic Algorithms December 4, 2013 4 / 20
Genes
The element from which this method derives it name, as genes are the
basic building blocks of life.
So too in our search for the solution for various problems, genes are the
basic elements we switch around and juggle with in order to arrive at a
more optimum solution.
George Bora (UTCN) Genetic Algorithms December 4, 2013 4 / 20
Allele
If genes are the basics of the solution in theory, alleles are the values
encoded in genes are the ones we use in practice, when developing
software which uses genetic programming.
George Bora (UTCN) Genetic Algorithms December 4, 2013 5 / 20
Allele
If genes are the basics of the solution in theory, alleles are the values
encoded in genes are the ones we use in practice, when developing
software which uses genetic programming.
When the time has passed and the solution must effectively be built or
instantiated it is the allele which forms the blue print we go by.
George Bora (UTCN) Genetic Algorithms December 4, 2013 5 / 20
Allele
If genes are the basics of the solution in theory, alleles are the values
encoded in genes are the ones we use in practice, when developing
software which uses genetic programming.
When the time has passed and the solution must effectively be built or
instantiated it is the allele which forms the blue print we go by.
In the original vision for genetic algorithms there was only 1 allele per
gene, which was a binary value and was stored in a 1 bit, as the 鍖eld
progressed all of those constrictions have been lifted.
George Bora (UTCN) Genetic Algorithms December 4, 2013 5 / 20
Chromosome and Individual
As in nature an animal can not have its information encoded in a single
gene, in programming a solution which warrants genetic algorithms is not
simple enough as to be composed on 1 gene.
George Bora (UTCN) Genetic Algorithms December 4, 2013 6 / 20
Chromosome and Individual
As in nature an animal can not have its information encoded in a single
gene, in programming a solution which warrants genetic algorithms is not
simple enough as to be composed on 1 gene.
Chromosomes are the collection of genes, which make up the blueprint
from which we will map our solution and create the individual.
George Bora (UTCN) Genetic Algorithms December 4, 2013 6 / 20
Chromosome and Individual
As in nature an animal can not have its information encoded in a single
gene, in programming a solution which warrants genetic algorithms is not
simple enough as to be composed on 1 gene.
Chromosomes are the collection of genes, which make up the blueprint
from which we will map our solution and create the individual.
If the chromosomes are the blue prints the individual is the end product,
to make an analogy with software engineering, and individual is to a class
what a instance is to a object.
George Bora (UTCN) Genetic Algorithms December 4, 2013 6 / 20
Mapping
The process by which we construct a individual from the chromosome we
have generated is called mapping, it is one of the important elements
(alongside chromosome structure and 鍖tness functions) we must consider
before we implement our design.
George Bora (UTCN) Genetic Algorithms December 4, 2013 7 / 20
Mapping
The process by which we construct a individual from the chromosome we
have generated is called mapping, it is one of the important elements
(alongside chromosome structure and 鍖tness functions) we must consider
before we implement our design. Mapping and its complexity is often tied
with how we de鍖ne our alleles,genes and chromosome as well as our
genetic operations, a great deal of planning being required in order to
produce the best possible algorithm.
George Bora (UTCN) Genetic Algorithms December 4, 2013 7 / 20
Crossover
Crossover is one of the fundamental operations within the toolbox of
genetic algorithms, and one of the most important methods by which we
can combine existing chromosomes to form new ones in the search for a
鍖t enough solution.
George Bora (UTCN) Genetic Algorithms December 4, 2013 8 / 20
Crossover
Crossover is one of the fundamental operations within the toolbox of
genetic algorithms, and one of the most important methods by which we
can combine existing chromosomes to form new ones in the search for a
鍖t enough solution. It involves separating each chromosome which takes
part into two parts, and then recombining parts from the different old
chromosomes to form the new set of chromosomes.
George Bora (UTCN) Genetic Algorithms December 4, 2013 8 / 20
Mutation
Mutation is the changing of the allele of a gene to another one of its
possible values.
George Bora (UTCN) Genetic Algorithms December 4, 2013 9 / 20
Mutation
Mutation is the changing of the allele of a gene to another one of its
possible values. This operation permits genetic algorithms to potentially
escape from local optimum solutions, a very important characteristic in the
鍖eld of arti鍖cial intelligence.
George Bora (UTCN) Genetic Algorithms December 4, 2013 9 / 20
Fitness Function
Via crossover and mutation we can create whole populations of
individuals, potential solutions, and so the question arises when do we
stop the evolutionary cycle?
George Bora (UTCN) Genetic Algorithms December 4, 2013 10 / 20
Fitness Function
Via crossover and mutation we can create whole populations of
individuals, potential solutions, and so the question arises when do we
stop the evolutionary cycle? The answer being when we have reached a
certain vicinity of an ideal solution, but for this we need to evaluate how
close is any one individual to satisfying our demands and being the sought
after solution.
George Bora (UTCN) Genetic Algorithms December 4, 2013 10 / 20
Fitness Function II
The implementation of the 鍖tness function changes from one class of
problems to another, standardization being much more dif鍖cult than with
genes, and is one of the most time consuming elements of genetic
programming.
George Bora (UTCN) Genetic Algorithms December 4, 2013 11 / 20
Fitness Function II
The implementation of the 鍖tness function changes from one class of
problems to another, standardization being much more dif鍖cult than with
genes, and is one of the most time consuming elements of genetic
programming.
Writing the 鍖tness function, which when given a chromosome will return
how 鍖t or close to the ideal it is, is one of the hardest yet essential tasks in
developing a solution with genetic programming as it is the only way to
close the loop and choose a 鍖nal solution.
George Bora (UTCN) Genetic Algorithms December 4, 2013 11 / 20
Genetic Algorithms vs Genetic Programming
Within this 鍖eld there exist two very different paradigms, genetic
algorithms and genetic programming the most visible difference between
them being the structure of the chromosomes they produce.
George Bora (UTCN) Genetic Algorithms December 4, 2013 12 / 20
Genetic Algorithms vs Genetic Programming
Within this 鍖eld there exist two very different paradigms, genetic
algorithms and genetic programming the most visible difference between
them being the structure of the chromosomes they produce.
Genetic algorithms work with a chromosome which is linear and often 鍖xed
in length, making them ideal for tunning the behavior of various solutions.
George Bora (UTCN) Genetic Algorithms December 4, 2013 12 / 20
Genetic Algorithms vs Genetic Programming
Within this 鍖eld there exist two very different paradigms, genetic
algorithms and genetic programming the most visible difference between
them being the structure of the chromosomes they produce.
Genetic algorithms work with a chromosome which is linear and often 鍖xed
in length, making them ideal for tunning the behavior of various solutions.
Genetic programming instead uses a tree-structured chromosome variable
in size, which allows it to generate the structure of the solution as well as
the behavior.
George Bora (UTCN) Genetic Algorithms December 4, 2013 12 / 20
The problem
The creation of a algorithm which is capable of classifying a target image,
returning information about the general structure, size and color (the
pre-de鍖ned classes) of the object present in the image.
George Bora (UTCN) Genetic Algorithms December 4, 2013 13 / 20
The problem
The creation of a algorithm which is capable of classifying a target image,
returning information about the general structure, size and color (the
pre-de鍖ned classes) of the object present in the image.
Requirements:
1 the use of genetic computing within the solution
2 as high of a success rate as possible
George Bora (UTCN) Genetic Algorithms December 4, 2013 13 / 20
Image classi鍖cation
Image recognition, which can be classi鍖ed as a sub-鍖eld of computer
vision, is a 鍖eld concerned with the identi鍖cation of objects and entities
within images.
George Bora (UTCN) Genetic Algorithms December 4, 2013 14 / 20
Image classi鍖cation
Image recognition, which can be classi鍖ed as a sub-鍖eld of computer
vision, is a 鍖eld concerned with the identi鍖cation of objects and entities
within images.
Image classi鍖cation is a classical image recognition problem in which the
task is to assign labels to images based their content or metadata.
George Bora (UTCN) Genetic Algorithms December 4, 2013 14 / 20
The classes
The labels we apply are called classes and for this algorithm we have
de鍖ned 3 great families of classes:
form classes: for now we have de鍖ned classes for circles,
triangles(isosceles) and circles although additions to these are
relatively easy to add due to our use of genetic algorithms
color classes: right now only red, green and blue are implemented
although using the rgb format is also possible.
size classes: chosen arbitrarily.
George Bora (UTCN) Genetic Algorithms December 4, 2013 15 / 20
The chromosome
The chromosome is fairly simplistic being formed out of:
a gene encoding the form.
a gene encoding the color.
a gene encoding the size.
George Bora (UTCN) Genetic Algorithms December 4, 2013 16 / 20
Genes and Allele
The genes governing shapes at the moment can have the following
values: circle, triangle and square all identi鍖ed by numeric codes.
George Bora (UTCN) Genetic Algorithms December 4, 2013 17 / 20
Genes and Allele
The genes governing shapes at the moment can have the following
values: circle, triangle and square all identi鍖ed by numeric codes. The
genes governing color at the moment can accept any color de鍖ned by the
SVG standard although they can also handle rgb codes, which would
require 3 separate genes.
George Bora (UTCN) Genetic Algorithms December 4, 2013 17 / 20
Genes and Allele
The genes governing shapes at the moment can have the following
values: circle, triangle and square all identi鍖ed by numeric codes. The
genes governing color at the moment can accept any color de鍖ned by the
SVG standard although they can also handle rgb codes, which would
require 3 separate genes.
The genes governing size are again numeric codes which represent hard
coded categories of size.
George Bora (UTCN) Genetic Algorithms December 4, 2013 17 / 20
Mapping
The mapping process is the most intensive one, in terms of time and lines
of code needed, followed closely by calculating the 鍖tness function.
The process consists of:
creating a SVG 鍖le from the chromosome requires only the standard
Java standard 鍖le API.
converting said .svg 鍖le to the .png (raster) format as the image we
are trying to classify will be a raster image, requires calls to the
Inkscape API via Javas system API.
George Bora (UTCN) Genetic Algorithms December 4, 2013 18 / 20
Fitness function
As the result of the mapping is a image of a similar raster format like the
one we seek to classify, the 鍖tness function simply does a naive
comparison of the two images bit by bit.
George Bora (UTCN) Genetic Algorithms December 4, 2013 19 / 20
Fitness function
As the result of the mapping is a image of a similar raster format like the
one we seek to classify, the 鍖tness function simply does a naive
comparison of the two images bit by bit.
It then normalizes the bit difference to a range between 0 and 1, as
required by the genetic algorithm, this 鍖tness being then used in the
standard manner for deciding which chromosomes pass into the next
generation.
George Bora (UTCN) Genetic Algorithms December 4, 2013 19 / 20
The cons
This procedure has a number of weak points:
genetic algorithms traditionally arent suited to image classi鍖cation.
the speed of this procedure, is very low due to the calls to Inkscape
and the creation of numerous 鍖les (can be improved).
the 鍖tness function relies on a very sensible and naive image
comparison method (can be improved).
George Bora (UTCN) Genetic Algorithms December 4, 2013 20 / 20
The pros
A number of points in its favour
the available class list, due to the classes being written in SVG, is
very easily extendable.
in its current form it requires only Java and Inkscape (a very available
software).
there are a large number of image comparison methods which can be
used for the 鍖tness function.
George Bora (UTCN) Genetic Algorithms December 4, 2013 21 / 20
The End
Thank your for your attention !
George Bora (UTCN) Genetic Algorithms December 4, 2013 22 / 20
The End
Thank your for your attention !
Any questions ?
George Bora (UTCN) Genetic Algorithms December 4, 2013 22 / 20
Ad

Recommended

Sinks Method Paper Presentation @ Duke Political Networks Conference 2010
Sinks Method Paper Presentation @ Duke Political Networks Conference 2010
Daniel Katz
2001: An Introduction to Artificial Immune Systems
2001: An Introduction to Artificial Immune Systems
Leandro de Castro
Characteristic & Classification of Sound
Characteristic & Classification of Sound
Pratik Nakrani
Characteristics of sound,teacherpres,ppt
Characteristics of sound,teacherpres,ppt
Felix Bunagan
Proposed genome for creating VHDL programs with genetic algorithms
Proposed genome for creating VHDL programs with genetic algorithms
George Bora
A Review On Genetic Algorithm And Its Applications
A Review On Genetic Algorithm And Its Applications
Karen Gomez
CSA 3702 machine learning module 4
CSA 3702 machine learning module 4
Nandhini S
Soft computing06
Soft computing06
university of sargodha
Introduction to Genetic Algorithm
Introduction to Genetic Algorithm
ramyaravindran12
Genetic algorithms full lecture
Genetic algorithms full lecture
sadiacs
Genetic algorithms
Genetic algorithms
Amna Saeed
Genetic Algorithm
Genetic Algorithm
Bhushan Mohite
Introduction to genetic algorithms
Introduction to genetic algorithms
shadanalam
CI_L02_Optimization_ag2_eng.pdf
CI_L02_Optimization_ag2_eng.pdf
SantiagoGarridoBulln
Genetic algorithm
Genetic algorithm
garima931
generic optimization techniques lecture slides
generic optimization techniques lecture slides
SardarHamidullah
Genetic algorithms
Genetic algorithms
Pradeep Kumar
Introduction to Genetic Algorithms
Introduction to Genetic Algorithms
Premsankar Chakkingal
Gadoc
Gadoc
rutika12345
Genetic-Algorithms for engineering appl.ppt
Genetic-Algorithms for engineering appl.ppt
prabhadasila2
3_GO_Olesya_Genetic_AlgorithmsOPTIMZTION.p.pdf
3_GO_Olesya_Genetic_AlgorithmsOPTIMZTION.p.pdf
ssuser8d8cfc1
Genetic algorithm optimization technique.pptx
Genetic algorithm optimization technique.pptx
sridharece1
CI_L11_Optimization_ag2_eng.pptx
CI_L11_Optimization_ag2_eng.pptx
SantiagoGarridoBulln
MACHINE LEARNING - GENETIC ALGORITHM
MACHINE LEARNING - GENETIC ALGORITHM
Puneet Kulyana
Data Science - Part XIV - Genetic Algorithms
Data Science - Part XIV - Genetic Algorithms
Derek Kane
introduction of genetic algorithm
introduction of genetic algorithm
ritambharaaatre
Introduction to Genetic Algorithms 2014
Introduction to Genetic Algorithms 2014
Aleksander Stensby
Soft Computing- Dr. H.s. Hota 28.08.14.pdf
Soft Computing- Dr. H.s. Hota 28.08.14.pdf
forsatyam9451
EIS-Webinar-Engineering-Retail-Infrastructure-06-16-2025.pdf
EIS-Webinar-Engineering-Retail-Infrastructure-06-16-2025.pdf
Earley Information Science
"Scaling in space and time with Temporal", Andriy Lupa.pdf
"Scaling in space and time with Temporal", Andriy Lupa.pdf
Fwdays

More Related Content

Similar to Genetic Algorithms and Image Classification (20)

Introduction to Genetic Algorithm
Introduction to Genetic Algorithm
ramyaravindran12
Genetic algorithms full lecture
Genetic algorithms full lecture
sadiacs
Genetic algorithms
Genetic algorithms
Amna Saeed
Genetic Algorithm
Genetic Algorithm
Bhushan Mohite
Introduction to genetic algorithms
Introduction to genetic algorithms
shadanalam
CI_L02_Optimization_ag2_eng.pdf
CI_L02_Optimization_ag2_eng.pdf
SantiagoGarridoBulln
Genetic algorithm
Genetic algorithm
garima931
generic optimization techniques lecture slides
generic optimization techniques lecture slides
SardarHamidullah
Genetic algorithms
Genetic algorithms
Pradeep Kumar
Introduction to Genetic Algorithms
Introduction to Genetic Algorithms
Premsankar Chakkingal
Gadoc
Gadoc
rutika12345
Genetic-Algorithms for engineering appl.ppt
Genetic-Algorithms for engineering appl.ppt
prabhadasila2
3_GO_Olesya_Genetic_AlgorithmsOPTIMZTION.p.pdf
3_GO_Olesya_Genetic_AlgorithmsOPTIMZTION.p.pdf
ssuser8d8cfc1
Genetic algorithm optimization technique.pptx
Genetic algorithm optimization technique.pptx
sridharece1
CI_L11_Optimization_ag2_eng.pptx
CI_L11_Optimization_ag2_eng.pptx
SantiagoGarridoBulln
MACHINE LEARNING - GENETIC ALGORITHM
MACHINE LEARNING - GENETIC ALGORITHM
Puneet Kulyana
Data Science - Part XIV - Genetic Algorithms
Data Science - Part XIV - Genetic Algorithms
Derek Kane
introduction of genetic algorithm
introduction of genetic algorithm
ritambharaaatre
Introduction to Genetic Algorithms 2014
Introduction to Genetic Algorithms 2014
Aleksander Stensby
Soft Computing- Dr. H.s. Hota 28.08.14.pdf
Soft Computing- Dr. H.s. Hota 28.08.14.pdf
forsatyam9451
Introduction to Genetic Algorithm
Introduction to Genetic Algorithm
ramyaravindran12
Genetic algorithms full lecture
Genetic algorithms full lecture
sadiacs
Genetic algorithms
Genetic algorithms
Amna Saeed
Introduction to genetic algorithms
Introduction to genetic algorithms
shadanalam
CI_L02_Optimization_ag2_eng.pdf
CI_L02_Optimization_ag2_eng.pdf
SantiagoGarridoBulln
Genetic algorithm
Genetic algorithm
garima931
generic optimization techniques lecture slides
generic optimization techniques lecture slides
SardarHamidullah
Genetic algorithms
Genetic algorithms
Pradeep Kumar
Introduction to Genetic Algorithms
Introduction to Genetic Algorithms
Premsankar Chakkingal
Genetic-Algorithms for engineering appl.ppt
Genetic-Algorithms for engineering appl.ppt
prabhadasila2
3_GO_Olesya_Genetic_AlgorithmsOPTIMZTION.p.pdf
3_GO_Olesya_Genetic_AlgorithmsOPTIMZTION.p.pdf
ssuser8d8cfc1
Genetic algorithm optimization technique.pptx
Genetic algorithm optimization technique.pptx
sridharece1
CI_L11_Optimization_ag2_eng.pptx
CI_L11_Optimization_ag2_eng.pptx
SantiagoGarridoBulln
MACHINE LEARNING - GENETIC ALGORITHM
MACHINE LEARNING - GENETIC ALGORITHM
Puneet Kulyana
Data Science - Part XIV - Genetic Algorithms
Data Science - Part XIV - Genetic Algorithms
Derek Kane
introduction of genetic algorithm
introduction of genetic algorithm
ritambharaaatre
Introduction to Genetic Algorithms 2014
Introduction to Genetic Algorithms 2014
Aleksander Stensby
Soft Computing- Dr. H.s. Hota 28.08.14.pdf
Soft Computing- Dr. H.s. Hota 28.08.14.pdf
forsatyam9451

Recently uploaded (20)

EIS-Webinar-Engineering-Retail-Infrastructure-06-16-2025.pdf
EIS-Webinar-Engineering-Retail-Infrastructure-06-16-2025.pdf
Earley Information Science
"Scaling in space and time with Temporal", Andriy Lupa.pdf
"Scaling in space and time with Temporal", Andriy Lupa.pdf
Fwdays
Salesforce Summer '25 Release Frenchgathering.pptx.pdf
Salesforce Summer '25 Release Frenchgathering.pptx.pdf
yosra Saidani
Lessons Learned from Developing Secure AI Workflows.pdf
Lessons Learned from Developing Secure AI Workflows.pdf
Priyanka Aash
Cyber Defense Matrix Workshop - RSA Conference
Cyber Defense Matrix Workshop - RSA Conference
Priyanka Aash
ReSTIR [DI]: Spatiotemporal reservoir resampling for real-time ray tracing ...
ReSTIR [DI]: Spatiotemporal reservoir resampling for real-time ray tracing ...
revolcs10
9-1-1 Addressing: End-to-End Automation Using FME
9-1-1 Addressing: End-to-End Automation Using FME
Safe Software
Coordinated Disclosure for ML - What's Different and What's the Same.pdf
Coordinated Disclosure for ML - What's Different and What's the Same.pdf
Priyanka Aash
PyCon SG 25 - Firecracker Made Easy with Python.pdf
PyCon SG 25 - Firecracker Made Easy with Python.pdf
Muhammad Yuga Nugraha
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
Fwdays
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
pcprocore
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC
"Database isolation: how we deal with hundreds of direct connections to the d...
"Database isolation: how we deal with hundreds of direct connections to the d...
Fwdays
2025_06_18 - OpenMetadata Community Meeting.pdf
2025_06_18 - OpenMetadata Community Meeting.pdf
OpenMetadata
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Josef Weingand
cnc-processing-centers-centateq-p-110-en.pdf
cnc-processing-centers-centateq-p-110-en.pdf
AmirStern2
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Nilesh Gule
Mastering AI Workflows with FME by Mark Doring
Mastering AI Workflows with FME by Mark Doring
Safe Software
10 Key Challenges for AI within the EU Data Protection Framework.pdf
10 Key Challenges for AI within the EU Data Protection Framework.pdf
Priyanka Aash
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik
EIS-Webinar-Engineering-Retail-Infrastructure-06-16-2025.pdf
EIS-Webinar-Engineering-Retail-Infrastructure-06-16-2025.pdf
Earley Information Science
"Scaling in space and time with Temporal", Andriy Lupa.pdf
"Scaling in space and time with Temporal", Andriy Lupa.pdf
Fwdays
Salesforce Summer '25 Release Frenchgathering.pptx.pdf
Salesforce Summer '25 Release Frenchgathering.pptx.pdf
yosra Saidani
Lessons Learned from Developing Secure AI Workflows.pdf
Lessons Learned from Developing Secure AI Workflows.pdf
Priyanka Aash
Cyber Defense Matrix Workshop - RSA Conference
Cyber Defense Matrix Workshop - RSA Conference
Priyanka Aash
ReSTIR [DI]: Spatiotemporal reservoir resampling for real-time ray tracing ...
ReSTIR [DI]: Spatiotemporal reservoir resampling for real-time ray tracing ...
revolcs10
9-1-1 Addressing: End-to-End Automation Using FME
9-1-1 Addressing: End-to-End Automation Using FME
Safe Software
Coordinated Disclosure for ML - What's Different and What's the Same.pdf
Coordinated Disclosure for ML - What's Different and What's the Same.pdf
Priyanka Aash
PyCon SG 25 - Firecracker Made Easy with Python.pdf
PyCon SG 25 - Firecracker Made Easy with Python.pdf
Muhammad Yuga Nugraha
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
Fwdays
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
CapCut Pro Crack For PC Latest Version {Fully Unlocked} 2025
pcprocore
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC
"Database isolation: how we deal with hundreds of direct connections to the d...
"Database isolation: how we deal with hundreds of direct connections to the d...
Fwdays
2025_06_18 - OpenMetadata Community Meeting.pdf
2025_06_18 - OpenMetadata Community Meeting.pdf
OpenMetadata
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Josef Weingand
cnc-processing-centers-centateq-p-110-en.pdf
cnc-processing-centers-centateq-p-110-en.pdf
AmirStern2
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Nilesh Gule
Mastering AI Workflows with FME by Mark Doring
Mastering AI Workflows with FME by Mark Doring
Safe Software
10 Key Challenges for AI within the EU Data Protection Framework.pdf
10 Key Challenges for AI within the EU Data Protection Framework.pdf
Priyanka Aash
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik
Ad

Genetic Algorithms and Image Classification

  • 1. Genetic Algorithms George Bora UTCN December 4, 2013 George Bora (UTCN) Genetic Algorithms December 4, 2013 1 / 20
  • 2. Computer Science to Evolutionary Computation Within the vast 鍖eld of computer science under its vast array of potential applications there exists the branch of arti鍖cial intelligence. George Bora (UTCN) Genetic Algorithms December 4, 2013 2 / 20
  • 3. Computer Science to Evolutionary Computation Within the vast 鍖eld of computer science under its vast array of potential applications there exists the branch of arti鍖cial intelligence. One of the sub-branches of arti鍖cial intelligence is evolutionary computation which seeks to achieve continuous optimization and combinatorial optimization by incorporating knowledge of natural evolution processes. George Bora (UTCN) Genetic Algorithms December 4, 2013 2 / 20
  • 4. Basic Concepts from Biology The basic building blocks for evolutionary computation, which have kept their names from their native science, are as follows: genes allele chromosome individual mapping mutation and crossover 鍖tness function George Bora (UTCN) Genetic Algorithms December 4, 2013 3 / 20
  • 5. Genes The element from which this method derives it name, as genes are the basic building blocks of life. George Bora (UTCN) Genetic Algorithms December 4, 2013 4 / 20
  • 6. Genes The element from which this method derives it name, as genes are the basic building blocks of life. So too in our search for the solution for various problems, genes are the basic elements we switch around and juggle with in order to arrive at a more optimum solution. George Bora (UTCN) Genetic Algorithms December 4, 2013 4 / 20
  • 7. Allele If genes are the basics of the solution in theory, alleles are the values encoded in genes are the ones we use in practice, when developing software which uses genetic programming. George Bora (UTCN) Genetic Algorithms December 4, 2013 5 / 20
  • 8. Allele If genes are the basics of the solution in theory, alleles are the values encoded in genes are the ones we use in practice, when developing software which uses genetic programming. When the time has passed and the solution must effectively be built or instantiated it is the allele which forms the blue print we go by. George Bora (UTCN) Genetic Algorithms December 4, 2013 5 / 20
  • 9. Allele If genes are the basics of the solution in theory, alleles are the values encoded in genes are the ones we use in practice, when developing software which uses genetic programming. When the time has passed and the solution must effectively be built or instantiated it is the allele which forms the blue print we go by. In the original vision for genetic algorithms there was only 1 allele per gene, which was a binary value and was stored in a 1 bit, as the 鍖eld progressed all of those constrictions have been lifted. George Bora (UTCN) Genetic Algorithms December 4, 2013 5 / 20
  • 10. Chromosome and Individual As in nature an animal can not have its information encoded in a single gene, in programming a solution which warrants genetic algorithms is not simple enough as to be composed on 1 gene. George Bora (UTCN) Genetic Algorithms December 4, 2013 6 / 20
  • 11. Chromosome and Individual As in nature an animal can not have its information encoded in a single gene, in programming a solution which warrants genetic algorithms is not simple enough as to be composed on 1 gene. Chromosomes are the collection of genes, which make up the blueprint from which we will map our solution and create the individual. George Bora (UTCN) Genetic Algorithms December 4, 2013 6 / 20
  • 12. Chromosome and Individual As in nature an animal can not have its information encoded in a single gene, in programming a solution which warrants genetic algorithms is not simple enough as to be composed on 1 gene. Chromosomes are the collection of genes, which make up the blueprint from which we will map our solution and create the individual. If the chromosomes are the blue prints the individual is the end product, to make an analogy with software engineering, and individual is to a class what a instance is to a object. George Bora (UTCN) Genetic Algorithms December 4, 2013 6 / 20
  • 13. Mapping The process by which we construct a individual from the chromosome we have generated is called mapping, it is one of the important elements (alongside chromosome structure and 鍖tness functions) we must consider before we implement our design. George Bora (UTCN) Genetic Algorithms December 4, 2013 7 / 20
  • 14. Mapping The process by which we construct a individual from the chromosome we have generated is called mapping, it is one of the important elements (alongside chromosome structure and 鍖tness functions) we must consider before we implement our design. Mapping and its complexity is often tied with how we de鍖ne our alleles,genes and chromosome as well as our genetic operations, a great deal of planning being required in order to produce the best possible algorithm. George Bora (UTCN) Genetic Algorithms December 4, 2013 7 / 20
  • 15. Crossover Crossover is one of the fundamental operations within the toolbox of genetic algorithms, and one of the most important methods by which we can combine existing chromosomes to form new ones in the search for a 鍖t enough solution. George Bora (UTCN) Genetic Algorithms December 4, 2013 8 / 20
  • 16. Crossover Crossover is one of the fundamental operations within the toolbox of genetic algorithms, and one of the most important methods by which we can combine existing chromosomes to form new ones in the search for a 鍖t enough solution. It involves separating each chromosome which takes part into two parts, and then recombining parts from the different old chromosomes to form the new set of chromosomes. George Bora (UTCN) Genetic Algorithms December 4, 2013 8 / 20
  • 17. Mutation Mutation is the changing of the allele of a gene to another one of its possible values. George Bora (UTCN) Genetic Algorithms December 4, 2013 9 / 20
  • 18. Mutation Mutation is the changing of the allele of a gene to another one of its possible values. This operation permits genetic algorithms to potentially escape from local optimum solutions, a very important characteristic in the 鍖eld of arti鍖cial intelligence. George Bora (UTCN) Genetic Algorithms December 4, 2013 9 / 20
  • 19. Fitness Function Via crossover and mutation we can create whole populations of individuals, potential solutions, and so the question arises when do we stop the evolutionary cycle? George Bora (UTCN) Genetic Algorithms December 4, 2013 10 / 20
  • 20. Fitness Function Via crossover and mutation we can create whole populations of individuals, potential solutions, and so the question arises when do we stop the evolutionary cycle? The answer being when we have reached a certain vicinity of an ideal solution, but for this we need to evaluate how close is any one individual to satisfying our demands and being the sought after solution. George Bora (UTCN) Genetic Algorithms December 4, 2013 10 / 20
  • 21. Fitness Function II The implementation of the 鍖tness function changes from one class of problems to another, standardization being much more dif鍖cult than with genes, and is one of the most time consuming elements of genetic programming. George Bora (UTCN) Genetic Algorithms December 4, 2013 11 / 20
  • 22. Fitness Function II The implementation of the 鍖tness function changes from one class of problems to another, standardization being much more dif鍖cult than with genes, and is one of the most time consuming elements of genetic programming. Writing the 鍖tness function, which when given a chromosome will return how 鍖t or close to the ideal it is, is one of the hardest yet essential tasks in developing a solution with genetic programming as it is the only way to close the loop and choose a 鍖nal solution. George Bora (UTCN) Genetic Algorithms December 4, 2013 11 / 20
  • 23. Genetic Algorithms vs Genetic Programming Within this 鍖eld there exist two very different paradigms, genetic algorithms and genetic programming the most visible difference between them being the structure of the chromosomes they produce. George Bora (UTCN) Genetic Algorithms December 4, 2013 12 / 20
  • 24. Genetic Algorithms vs Genetic Programming Within this 鍖eld there exist two very different paradigms, genetic algorithms and genetic programming the most visible difference between them being the structure of the chromosomes they produce. Genetic algorithms work with a chromosome which is linear and often 鍖xed in length, making them ideal for tunning the behavior of various solutions. George Bora (UTCN) Genetic Algorithms December 4, 2013 12 / 20
  • 25. Genetic Algorithms vs Genetic Programming Within this 鍖eld there exist two very different paradigms, genetic algorithms and genetic programming the most visible difference between them being the structure of the chromosomes they produce. Genetic algorithms work with a chromosome which is linear and often 鍖xed in length, making them ideal for tunning the behavior of various solutions. Genetic programming instead uses a tree-structured chromosome variable in size, which allows it to generate the structure of the solution as well as the behavior. George Bora (UTCN) Genetic Algorithms December 4, 2013 12 / 20
  • 26. The problem The creation of a algorithm which is capable of classifying a target image, returning information about the general structure, size and color (the pre-de鍖ned classes) of the object present in the image. George Bora (UTCN) Genetic Algorithms December 4, 2013 13 / 20
  • 27. The problem The creation of a algorithm which is capable of classifying a target image, returning information about the general structure, size and color (the pre-de鍖ned classes) of the object present in the image. Requirements: 1 the use of genetic computing within the solution 2 as high of a success rate as possible George Bora (UTCN) Genetic Algorithms December 4, 2013 13 / 20
  • 28. Image classi鍖cation Image recognition, which can be classi鍖ed as a sub-鍖eld of computer vision, is a 鍖eld concerned with the identi鍖cation of objects and entities within images. George Bora (UTCN) Genetic Algorithms December 4, 2013 14 / 20
  • 29. Image classi鍖cation Image recognition, which can be classi鍖ed as a sub-鍖eld of computer vision, is a 鍖eld concerned with the identi鍖cation of objects and entities within images. Image classi鍖cation is a classical image recognition problem in which the task is to assign labels to images based their content or metadata. George Bora (UTCN) Genetic Algorithms December 4, 2013 14 / 20
  • 30. The classes The labels we apply are called classes and for this algorithm we have de鍖ned 3 great families of classes: form classes: for now we have de鍖ned classes for circles, triangles(isosceles) and circles although additions to these are relatively easy to add due to our use of genetic algorithms color classes: right now only red, green and blue are implemented although using the rgb format is also possible. size classes: chosen arbitrarily. George Bora (UTCN) Genetic Algorithms December 4, 2013 15 / 20
  • 31. The chromosome The chromosome is fairly simplistic being formed out of: a gene encoding the form. a gene encoding the color. a gene encoding the size. George Bora (UTCN) Genetic Algorithms December 4, 2013 16 / 20
  • 32. Genes and Allele The genes governing shapes at the moment can have the following values: circle, triangle and square all identi鍖ed by numeric codes. George Bora (UTCN) Genetic Algorithms December 4, 2013 17 / 20
  • 33. Genes and Allele The genes governing shapes at the moment can have the following values: circle, triangle and square all identi鍖ed by numeric codes. The genes governing color at the moment can accept any color de鍖ned by the SVG standard although they can also handle rgb codes, which would require 3 separate genes. George Bora (UTCN) Genetic Algorithms December 4, 2013 17 / 20
  • 34. Genes and Allele The genes governing shapes at the moment can have the following values: circle, triangle and square all identi鍖ed by numeric codes. The genes governing color at the moment can accept any color de鍖ned by the SVG standard although they can also handle rgb codes, which would require 3 separate genes. The genes governing size are again numeric codes which represent hard coded categories of size. George Bora (UTCN) Genetic Algorithms December 4, 2013 17 / 20
  • 35. Mapping The mapping process is the most intensive one, in terms of time and lines of code needed, followed closely by calculating the 鍖tness function. The process consists of: creating a SVG 鍖le from the chromosome requires only the standard Java standard 鍖le API. converting said .svg 鍖le to the .png (raster) format as the image we are trying to classify will be a raster image, requires calls to the Inkscape API via Javas system API. George Bora (UTCN) Genetic Algorithms December 4, 2013 18 / 20
  • 36. Fitness function As the result of the mapping is a image of a similar raster format like the one we seek to classify, the 鍖tness function simply does a naive comparison of the two images bit by bit. George Bora (UTCN) Genetic Algorithms December 4, 2013 19 / 20
  • 37. Fitness function As the result of the mapping is a image of a similar raster format like the one we seek to classify, the 鍖tness function simply does a naive comparison of the two images bit by bit. It then normalizes the bit difference to a range between 0 and 1, as required by the genetic algorithm, this 鍖tness being then used in the standard manner for deciding which chromosomes pass into the next generation. George Bora (UTCN) Genetic Algorithms December 4, 2013 19 / 20
  • 38. The cons This procedure has a number of weak points: genetic algorithms traditionally arent suited to image classi鍖cation. the speed of this procedure, is very low due to the calls to Inkscape and the creation of numerous 鍖les (can be improved). the 鍖tness function relies on a very sensible and naive image comparison method (can be improved). George Bora (UTCN) Genetic Algorithms December 4, 2013 20 / 20
  • 39. The pros A number of points in its favour the available class list, due to the classes being written in SVG, is very easily extendable. in its current form it requires only Java and Inkscape (a very available software). there are a large number of image comparison methods which can be used for the 鍖tness function. George Bora (UTCN) Genetic Algorithms December 4, 2013 21 / 20
  • 40. The End Thank your for your attention ! George Bora (UTCN) Genetic Algorithms December 4, 2013 22 / 20
  • 41. The End Thank your for your attention ! Any questions ? George Bora (UTCN) Genetic Algorithms December 4, 2013 22 / 20