Memetic Learning
Philosophy Behind Memetics
Genetic Algorithm – Intuition and Structure
Memetic learning
meme
Memetic Algorithms
First generation MA
Second generation MA
Third generation MA
Solution of N Queens Problem with MA
Conclusion
2. Supervised by
Dr. Fawzia R.
Mosul University
Computer Sciences Department
Master Student 2018 - 2019
Mohammed Al-Kazal
ADVANCE ARTIFICIAL INTELLIGENCE
3. Overview
Philosophy Behind Memetics
Genetic Algorithm – Intuition and Structure
Memetic learning
• meme
Memetic Algorithms
• First generation MA
• Second generation MA
• Third generation MA
Solution of N Queens Problem with MA
Conclusion
5. BiologicalEvolution • Use and Disuse
• Inheritance of acquired characteristics
Charles Robert Darwin
1809 –1882
• Natural Selection
• Survival of The Fittest
• Origin of New Species
Jean-Baptiste Lamarck
1744 –1829
6. Genes and biological Evolution
A gene is a unit of biological information
transferred from one generation to another.
Genes determine our physical traits, what
you look like, what you inherit from either
one of your parents.
7. Genetic Algorithm
solves (typically optimization) problems by
combining features of complete solutions to
create new populations of solutions.
applicable when it is hard or unreasonable
to try to completely identify a sub problem
hierarchical structure or to approach the
problem via an exact approach.
12. Disadvantages&weaknessof
GA
• GAs are not ‘silver bullets’ for solving problems
(Global Optimization Algorithm).
• Must be able to assess the quality of each attempt at
a solution.
can’t crack Pretty Good Privacy with a GA.
• Computationally expensive.
some problems require many days or weeks to run.
often still faster than brute force, however.
• Blind, undirected search.
difficult to direct a GA towards optimal solution area
if known.
• Can be sensitive to initial parameters.
parameters such as mutation can significantly
influence the search.
• Stochastic process.
not guaranteed to find an optimal solution, just
highly likely to.
14. But what we do
in all our lives ?
Is this the only way of evolution ?
15. Memetic Learning
R. Dawkins, The Selfish Gene
“When you plant a
fertile meme in my
mind you literally
parasitize my brain,
turning it into a
vehicle for the
meme's propagation
in just the way that a
virus may parasitize
the genetic
mechanism of a
host cell.”
17. Meme
“the basic unit of cultural transmission,
or imitation”
Richard Dawkins
“an element of culture that may be
considered to be passed on by non-
genetic means”
English Oxford Dictionary
18. ExamplesofMeme Fashion
Latest trends are ideas of fashion
designers
Science
Scientists sharing their thoughts
Literature
Novel, poetry
Music
Even birds are found to imitate songs of
other birds!!!
19. Genes and Memes, where they are
similar
Genes propagate biologically from
chromosome to chromosome
Memes propagate from brain to
brain via imitation
Survival of fittest in meme
Concept of Good is survived though no
scientific evidence is present
20. Genes and Memes, where they
different
Genes are pre-decided
Genes are static through generations,
memes can be changed!
Memes allow improvement
After learning language, we contribute to it
through literature
New heuristics to 8-puzzle problem solved in
class
We use this property to improve genetic
algorithms
21. Memeticlearning the idea of memetic learning. Memetic learning is
directly inspired by Dawkins notion of the
acquisition of memes through imitation.
Memetic learning is based on imitation—people
learn, not only from their own direct
experiences with the world, but also by
following patterns, models, or examples they
have observed.
This imitation is an active process by which
people acquire the components of cultural
knowledge.
This process provides a rich metaphor on which
several related machine-learning methods can
be based.
These methods will be known collectively as
22. Memetic algorithms (MAs) now represent one
of the recent growing areas of research in
evolutionary computation.
The term MA is now widely used as a synergy
of evolutionary or any population-based
approach with separate individual learning or
local improvement procedures for problem
search.
Quite often, MAs are also referred to in the
literature as Cultural algorithms, Hybrid
Evolutionary Algorithms, Baldwinian
evolutionary algorithms (EAs), Lamarckian
EAs, or genetic local search.
Memeticalgorithms
(MAs)
proposed by Moscato (1989)
23. Memeticalgorithms
(MAs)
Moscato recognized that there are at
least two great differences between
biological evolution and cultural
evolution:
individuals cannot choose their
own genes whereas memes
can be acquired intentionally.
Individuals may modify and
improve upon the memes that
they acquire, whereas they
27. So.. What Are Memetic
Algorithms?
MAs, one of the key methodologies behind successful
discrete/continuous optimization, are:
a carefully orchestrated interplay
between (stochastic) global
search and (stochastic)local
search algorithms
An MA is an EA that includes one or
more local search phases within its
evolutionary cycle
32. Memetic Learning
A population of individuals with random alleles
for each meme is constructed and tested on
the task.
Individuals observe their own overall fitness
values and those of the other individuals in the
population.
Further they observe the partial fitness values
of the partial candidate solutions that they are
able to identify, both for themselves and for the
others.
They then replace their memes for those
portions of the solution for which they have low
fitness values, using imitation.
33. DesignIssuesforMAs We mast balance between the genetic
and the local search parts of memetic
algorithms .This leads naturally to
questions such as the following:
Where and when should local search be applied
within the evolutionary cycle.
Which individuals in the population should be
improved by local search, and how should they
be chosen.
How much computational effort should be
allocated to each local search.
How can the genetic operators best be
integrated with local search in order to achieve a
synergistic effect.
34. “What is the best tradeoff
between local search and
the global search provided
by evolution”
DesignIssuesforMA How often should individual learning be applied.
On which solutions should individual learning be
used.
How long should individual learning be run.
What individual learning method or meme should
be used for a particular problem or individual.
36. In Multi-meme MA, the memetic material is
encoded as part of the genotype.
The decoded meme of each respective
individual/chromosome is used to perform a
local refinement.
The memetic material is transmitted through
a simple inheritance mechanism from parent
to offspring(s).
In Multi-meme MA the pool of candidate
memes considered will compete, based on
their past merits in generating local
improvements through a reward mechanism,
deciding on which meme to be selected to
proceed for future local refinements. Memes
with a higher reward have a greater chance
of being replicated or copied.
MASecondGeneration
37. 3rd generation MA utilizes a rule-based local
search to supplement candidate solutions
within the evolutionary system, thus
capturing regularly repeated features or
patterns in the problem space.
There'dGenerationMA In 2nd generation MA we assumes that the memes
to be used are known a priori.
individual can select his meme
Individual can have more than
one meme
40. NQueensProblemGA
Cross over every two parents to random point
Sorting the generation from the highest value of fitness
function to the lower one
Duplicate the higher half of the generation and neglect the
lowest
Start
Create initial population random
Chromosome
fond in solation
Copy chromosome and all
his symmetric to solution
Yes
YesNo
Calculates fitness
any = maximum
fitness
Q = 1
No
Q = Q + 1
Mutation random gene in random children's
Q < generation
number
Print solution array
Yes No
NewGeneration
YesNo
Yes No
No
41. One Point cross over
Ex: random cross over point =3
CrossoverinGA
42. MutationinGA Select a number of individuals randomly from the
generation for mutation
Mutation is
Random change to break typical
43. Mutation random gene in
random children's
NQueensProblemMA
Cross over every two parents to random point
Sorting by fitness & Duplicate the higher half
Start
Create initial population random
Chromosome
fond in solation
Copy chromosome
and all his symmetric
to solution
Yes
YesNo
Calculates fitness
any = maximum
fitness
Q = 1
No
Q = Q + 1
Q < generation
number
Print solution array
Yes
YesNo
Yes No
No
Sorting by fitness
Local Search (meme)
44. • Select a subset M of random
individuals from the generation.
• For each individual in M Apply
local search (generate neighbor)
for t times.
• Add the new individual to the
generation .
LocalsearchinMA
45. LocalsearchinMA
2 4 5 8 1 7 3 6
Top
………
………
………
……
……
Random point
1
If (Fitness before < Fitness after )
copy
Generation Subset M
Then Update individual
t
2 4 1 8 5 7 3 6
Random point
2
46. • Select a subset M of random
individuals from the generation.
• For each individual in M Apply
local search to t times with
Meme .
• Add the new individual to the
generation .
LocalsearchMemeticlearning
47. Memeticlearning
2 4 4 8 1 7 3 6
Top
………
………
………
……
……
Meme (best solution in generation)
Random point
3 5 2 8 1 7 4 6
If (Fitness before < Fitness after )
copy
Generation
Subset M
Then Update individual
t
2 5 3 8 1 7 4 6
48. • Split generation into N groups of
random individuals from generation.
• For each group n:
• For each individual in the group
Apply local search to tn times with
meme n.
• Add the new individual to the
generation.
LocalsearchMultiMemeticlearning
49. 2 5 4 8 1 7 3 6
Meme
1
Meme2
Meme3
….
………
………
………
……
……
Meme n (one of best solution in generation)
Random point
3 5 2 8 1 7 4 6
If (Fitness before < Fitness after )
copy
Generation
Subset 1
Then Update individual
tn
……
……
Subset n
……
…....
……
2 5 3 8 1 7 4 6
LocalsearchMultiMemeticlearning
50. Conclusion A genetic algorithm promises convergence
but not optimality.
But we are assured of exponential
convergence, possibly at different optimal
chromosomes.
We can reach Optimal solution from
Memetic Learning (Genetic Algorithm with
Local Search).
In MA we mast balance between the genetic
and the local search parts of memetic
algorithms .
It enables us to deal with problems of high
change in performance and ambiguous
problems
52. References
Ahmad, R., Jamaluddin, H., Hussain, M.A.: Application of memetic algorithm in
modelling
discrete-time multivariable dynamics systems. Mech. Syst. Signal Process. 22,
1595–1609 (2008)
R. Dawkins, “The Selfish Gene – new edition”, Oxford University Press, 1989
pp 189-201
David E. Goldberg, Genetic Algorithms in Search, Optimization and Machine
Learning, 1st edition, Addison-Wesley Longman Publishing Co., 1989 pp 170-
174
B. Freisleben and P. Merz, New Genetic Local Search Operators for the Traveling
Salesman Problem. In H.-M. Voigt, W. Ebeling, I. Rechenberg, and H.-P.
Schwefel, editors, Proceedings of the 4th Conference on Parallel Problem
Solving from Nature - PPSN IV, pages 890--900. Springer, 1996
S. Lin and B. W. Kemighan, An effective heuristic algorithm for the Traveling
Salesman problem, Operation Research 21 (1973) 498-516
7.) Moscato, P. (1989). On Evolution, Search, Optimization, Genetic Algorithms
and Martial Arts:Towards Memetic Algorithms. Technical Report Caltech
Concurrent Computation Program,Report. 826, California Institute of Technology,
Pasadena, California, USA.
Singh, S. P. and Sutton, R. S. (1996). Reinforcement learning with replacing
eligibility traces.Machine Learning, 22:123–158.
Sutton, R. S. and Barto, A. G. (1998). Reinforcement Learning: An Introduction.
MIT Press.Yao, X. (1999). Evolutionary computation comes of age. Cognitive
Systems Research, 1:59–64.