Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crossover2 and weightmapping #1

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

AndrewLouw
Copy link
Owner

New crossover technique which leads to a closer relation to actual evolution (whole population converges) , weightmapping diagram shows this nicely.

AndrewLouw added 9 commits May 4, 2017 02:22
Crossover 2 takes a random city and finds it's position in the parent's
order vector, then choses one parent randomly but weighted based on
their performance and places thic city in the output vector in this
position. If the first choice parent's position is taken alread the
second choice is used, if both are taken it is placed randomly at the
end. Mutations prevent the whole population becoming identical and
introduce new samples occasionall. Works well with weightmapping -
replaces crossover in sketch.
the whole population is displayed at once in the upper figure. The
thickness of the lines are proportional to how many networks take that
route. Making it easy to see if the population is evolving or randomly
guessing.
comparison now squares to give better one a bigger advantage, mutation
is now recursive to increase double mutation chance.
mutate is a random swap not shuffle, testing more cities and different
probabilities.
Mutate function wasn't running in DNA but works in skech, more features
have been added and some values fiddled.
Mutate was being called but not returning a value, ultimately leading to
crasthes but more annoyingly not actually modifying the order. also now
every1000 generations there are 5 generataions of extream mutation to
help keep things progressing. The best ever is always in the population
now also
used the wrong variable name in one place
Added 10000th roor parenting this very mild bias towards the better
parent means slightly inefficent networks can form a breeding population
allowing improvements which require muliple mutations to be found -
anything is better than equal parenting however.
apocalypse spelling correction... and happens more often with more
mutations but is shorter.
Maximum stack exceeded error prevented (was low probability)
Now 'solves' for 50 cities in about 5 minutes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant