Darwinbots Forum

Bots and Simulations => DNA - General => Tips and Tricks => Topic started by: Botsareus on April 11, 2005, 12:04:49 PM

Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 12:04:49 PM
Ok never put all your mutation rates less then 200 , you wont get any overflows but the robots will mutate to fast.

Now to solve the fatal error problem in 2.36.2 do this: Put your mutation rate of mutation rates to 1, thats right to 1. I have no idea how or why that stops it seems to do so, I only ran one simulation maybe it was just luck, but hey try anyway.

****

In other news:

The rate of change of mutation rates is changing the mutation values to slow even if it is set to 1, strange things; the maximum change I got was for "delete instruction" witch was from 200 --> 220 , I want to see stuff like from 200 ---> 1500 if I set it to 1. It also should matter based on size:  

change from 200 ---> 1500

is only

change from 26 ----> 200

on smaller scales.

I am not sure if it already works like that, I have a feeling it does but the changes are to short the way I already explained. with a change of 1 its must be 200 ---> 1500 , 26 ---> 200 ...
Title: NO MORE OVERFLOW
Post by: PurpleYouko on April 11, 2005, 12:30:00 PM
Why would you want mutation rates to change that rapidly?  :blink:

It should be a gradual thing, not a giant leap into the unkown.

All the mutations in 2.36.2 now adapt at a rate proportional to the present size of a value. I used a Gaussian plot to control the change of values. The minimum range is 100 (so that a very low value such as 1 or 2 is still able to mutate) but as the values get higher the range is restricted to 10% of the present value.

In 2.36.1 all values are 100% random from -32000 up to +32000
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 12:33:53 PM
:devil: I am evil monkey thats why  :devil:
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 12:39:48 PM
what does my post say, The mutation rate of mutation rates , does not change rates fast enough should be 200-> 1500 on 1 at least. We need that so if robots deside not to mutate a sertain rate the change will be atleast notisable:

Ok what I mean is on 1 the change must be 200 -----> (2000*rnd) on avrage ---> 1100

on 26 must be ----> (266 * rnd) on avrage ---> 146

I think that causes a lot of errors when it is on mutation rate of mutation rates: 20 or 30 or bigger.

But no, no sutch thing , I am evil thats why I say this thing.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 12:41:12 PM
Keyword mutation rate of mutation rate = 1!!!!!!!! (not 100!!!!!!) then it should be BIG CHANGE....


When it is 100 it should be small change , (not "this program has caused a fatel error please send it to microslot bc kids should not be messing with softwear like that  anyway, we call it an error report for good mesure")
Title: NO MORE OVERFLOW
Post by: PurpleYouko on April 11, 2005, 01:10:35 PM
Yup  (http://s9.invisionfree.com/DarwinBots_Forum/index.php?showtopic=329&view=findpost&p=446596)
I was right.

Completely bloody Barking mad!  :wacko:
Title: NO MORE OVERFLOW
Post by: Numsgil on April 11, 2005, 04:36:39 PM
It's my opinion that bots (the little circle things, not the person) shouldn't be able to mess with the mutation rates anyway.  A smart bot will just evolve to keep them as low as possible.  Probably anyway.  I'd recommend keeping it at 0.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 04:43:01 PM
Thats not true num, a smart bot will not evolve to have no mutation rates, I DONT WANT THE BOTS TO BE ABLE TO SET IT TO ZERO AT ALL. WHY? SIMPLE NUM, I KNOW FOR A FACT THAT MUTATION MAKES THINGS BETTER!!!!!! , IT DOES NOT DESTROY THINGS NUM, CORRECT MUTATION WILL MAKE THINGS BETTER NUM!!!!!
IF ONLY I HAD MY OLD FILES I WOULD PROVE IT TO YOU NUM, SO SAD THAT I DONT HAVE MY OLD FILES.

Quote
. A smart bot will just evolve to keep them as low as possible.

why would you say somthing like that? DB is currently not a good example of a mutation sim Num... Don't base everything on what you seen in DB.
Title: NO MORE OVERFLOW
Post by: Numsgil on April 11, 2005, 05:02:45 PM
While the cumulative effect of mutations over many, many generations generally produces better results than the precursor, any SINGLE bot would be wise to not allow mutations.

Why is that?

Imagine this:
You have a kid.  It's healthy and normal.  I tell you that there's a 99.9% chance that what I'm about to do will kill it, but there's a .1% chance that it will raise its IQ by 3 points.  Would you do it?

Now imagine I did that to every kid in the world.  Sure there'd only be a few million people left, but they'd all be smarter.  Right.  Still not a good move.

Now imagine I did it randomly to every thousandth kid that was born over the course of all human history.  The parents have no choice.  It doesn't adversely effect the entire human population, and it doesn't really effect most kids.  Some kids though will gain that 3 points of IQ.  Over time (say millions of years) you'd expect to see a massive increase in the intelligence of humans.

Mutations are like that.  Most, especially for smaller bots, are destructive.  You'd be a fool to let your kids have any chance at all of mutating.  You obviously were successful enough to survive.  What's wrong with your own genes?

But a species would be very wise to let itself mutate.  Slowly, ever so slowly, of course.  It's a funny dichotomy.  The same problem exists with cooperative bacteria.  Why do some cooperate to help others when it means their death?  From their point of view it means they can't pass on their genes.  Cheaters could develop that take advantage of them.

From the species' point of view it makes sense though.  If two together are stornger than two appart, you want them to work like that.

That's what I mean.  Remember, evolution, according to modern biologists, only works from the individual's point of view, sicne it is individuals that must compete and reproduce.
Title: NO MORE OVERFLOW
Post by: Carlo on April 11, 2005, 05:26:57 PM
Sorry, Nums, I can't understand your point. At the end of your post you say "evolution, only works from the individul's point of view". And that's right. So, how can you say that the interest of single robots should be to keep their mutation rates at 0, because mutation is in the species' interest?
If evolution works from the individual's point of view, and species evolve, this must be because mutating is in the individual's interest.
View it this way. Many biologists even say that evolution works from the gene point of view, that is mutation is in the interest of the genes, not even the individuals. Suppose you have a robot with n genes, and one of those genes is able to specify the global mutation rates for that robot. That gene should be more likely to spread if it triggers little enough mutations to preserve the dna functionality, but, at the same time, it has to trigger some because this increase its probability to spread in an environment subject to slow changes.
Anyway, I did some experiments with DarwinBots some time ago. I took some kind of rather primitive robot (like C. Circumgirans, or so) and cloned it (loaded it two times in the same simulation), creating two teams. One of them had a zero mutation rate, and the other one a low mutation rate, greater than zero. Then a ran a few simulations, and - surprise!- usually the team with a non-zero mutation rate won the sim. Well, now you have teams and auto reloading of sims with stats, so you can make some more accurate study about it. Who wants to try?

Bye, C.
Title: NO MORE OVERFLOW
Post by: Endy on April 11, 2005, 05:34:21 PM
The bots can mutate "naturally" without setting any mutation rates. With waste occasionally a bot will store something in mrepro. I haven't done any long term experiments yet but it's interesting to watch.

Endy B)
Title: NO MORE OVERFLOW
Post by: Carlo on April 11, 2005, 05:48:13 PM
Quote
The bots can mutate "naturally" without setting any mutation rates. With waste occasionally a bot will store something in mrepro.
Oh God, my knowledge of DarwinBots is sooo outdated.
On the other side, sometimes a find asking myself - possible that they _really_ know each of the tons of interactions rules they have put in it?   :)
Title: NO MORE OVERFLOW
Post by: Numsgil on April 11, 2005, 05:50:02 PM
Quote
If evolution works from the individual's point of view, and species evolve, this must be because mutating is in the individual's interest.
Close.  Remember that real organisms can't really control thier own mutation rates.  When they copy DNA, they try very hard to keep it as accurate as possible.

So my point is that species evolve because individuals can't control their own rate of mutation.

That's my hypothesis anyway.  Try a sim with two teams: one with rates of mutations rates of mutations set to like 1, the other with set to 0.  Keep the simulation settings changing from time to time.  Run it a few times (note that Dom Inv can beat itself in a sim with 0 mutations within a few thousand cycles).

See what happens.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 05:59:51 PM
Num try the same thing with the rates set to 200 , try it a couple of times, not to mesion it should work with the "broken mutations" and still make the bots better.

Your din thats not mutating should die out Num, thats how I evolved bot4g rimember?
Title: NO MORE OVERFLOW
Post by: Shen on April 11, 2005, 06:07:38 PM
IMO it all depends on so many factors that unless you have a specific idea in mind you cant really say. For example if I run my killer multibot Dimacheri with mutations it will definatly lose against a non mutating version simply because its so complicated, even a minor change will completly screw it up. But on the other hand something very basic will survive mutations much more easily.

Although one of Carlos points gave me an idea. The arena in DB pretty much stays the same so mutations aren't needed as much to adapt to new climates. But how about using the triggers to alter the veggie feed/repop rates? Say like..

IF 'Number of Bots more than 100' THEN 'set veggie feed rate at 5'

Ill post this in the suggestions thread.. :)
Title: NO MORE OVERFLOW
Post by: Numsgil on April 11, 2005, 06:07:56 PM
No Bots, they're both mutating.  But one is mutating his rates of mutation and the other isn't.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 06:09:47 PM
Interesting, I will try it.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 06:19:21 PM
NO NUM, THE ROBOT WITH THE RATES CHANGING WINS! AND THIS IS IN THE "NOT WORKING" VIRSION WITCH IS THE DOWNLOAD FROM THE NEW FTP DB 2.36.2 WITCH PY DID NOT FIX YET.
Title: NO MORE OVERFLOW
Post by: Numsgil on April 11, 2005, 06:29:43 PM
Bots, I told you you have to do it more than once.  Two identical copies of the same bot will eventually battle each other until only one is left.  Set up a statistical experiment where the winner has to have won half(number of rounds) + sqr(number of rounds).
Title: NO MORE OVERFLOW
Post by: Carlo on April 11, 2005, 06:34:49 PM
Quote
For example if I run my killer multibot Dimacheri with mutations it will definatly lose against a non mutating version ...

I think this happens because fighter bots are designed to be perfectly fit in their own environment, and also because they have no redundancies, etc. You should take for the try some evolved bots with all their "junk dna", as it was c. circumgirans.

Anyway, why doesn't anybody take care of all these tries - also those suggested by numsgil-? It would be extremely interesting to make a serious study, with all the numbers, graphs, etc., from the biological point of view. Shvarz, are you reading this? What do you think about it, a statistical study of the (possible) advantage given to a species by a mutation rate in an alife sim?

Quote
Although one of Carlos points gave me an idea. The arena in DB pretty much stays the same so mutations aren't needed as much to adapt to new climates.

Hmmm... and what about a programmable change of environment, say: "in the next 10 million cycles, slightly change friction (or costs, or whatever else) from <startvalue> to <endvalue>". They you go to sleep, and the morning after...
Title: NO MORE OVERFLOW
Post by: Botsareus on April 11, 2005, 06:58:48 PM
I did it more then once , the difference is very little but my first bot with mutating rates does better.
Title: NO MORE OVERFLOW
Post by: shvarz on April 11, 2005, 11:42:51 PM
Yes, I am reading this.  But it is not an easy question, it will depend on many things and needs some serios statistical analysis and so on.  BTW, the way graphs are working now, it is impossible to see any long-term trends.

  Right now I am evolving a bot that can hunt for moving low-anundance food in sims with high friction.  I am over 25 million cycles now and beleive me that the evolved bots are much better than the one I started with.  I actually tried to put them against each other and the parent gets its brains knocked out.

I don't know for sure, cause Bots does not give details on his sims, but my impression is that he sets mutation rate too high.  The result is that he gets two effects combined: "Mueller's ratchet" and "error catastrophie" - both lead to decrease in fitness over time and the "mutating bot" will lose.
Title: NO MORE OVERFLOW
Post by: Numsgil on April 12, 2005, 12:12:56 AM
Hey Schvarz, since you're our resident mutation expert (seeing as how you run them longer then most others) you should write up a short article on what settings to use, what you should expect to see, how to sort through the bots you get, etc.  Would be really interesting.

Also, what is Mueller's ratchet and error catastrophe?  I think I understand what you mean but I'd be interested in finding out for sure.
Title: NO MORE OVERFLOW
Post by: AZPaul on April 12, 2005, 04:31:23 AM
Mueller's ratchet. Ahh, yes. Within most asexually reproducing species the buildup of diliterious genes will, eventually crash the population, even to extinction. Some corollaries in small inbred sexual populations as well...like Arkansas.

May I make one observation? Picky, I know, but do let's keep things straight.

"Evolution" does not happen to individuals. It happens to populations. It is the basis of speciel events and an individual does not constitute a species. Populations do. Individuals suffer mutations which add (maybe) to genetic variation within the population which leads to adaption (maybe) to changing environments. No individual evolves.  

Mutations may or may not be in the "individuals" best interest. Mutations are random events that have whatever effect they have and the individual suffers or prospers accordingly.

Mutations [you]are[/you] in the best interests of the "population." Individuals with dilitarious mutations (usually) do not survive to reproduce, thus, for a population over many generations, survived mutations add considerable genetic variation to the gene pool.

When the inevitable environmental change occurs, the more genetically varied the population the better the chance that some combination of available alleles (ex-mutations now ubiquitous within the population) will produce individuals better able to cope (fitter) in the changing environment. Or maybe not.

As for Bot's desire for a faster rate of mutation rates:

Keep in mind that in a simulator like DB the mutation rate, and the rate of mutation rates, is synonymous with overall evolutionary time. One way to simulate great lengths of time is to have a high rate of mutations and a high rate of change in those rates. The other side of the simulation, to make this time scale accurate, must be a very short individual life span.  

Since beneficial mutations, and allele variability, are slow to work through even a subset of a population, the higher the mutation rate the higher the generation "turnover" must be to weed out the bad (but lucky, since it may have been, by fluke, passed on to one generation) mutation and make the good alleles more frequent in the population.

In the absence of this, Shvarz has got it right. Not enough generations for natural selection to work, you end up with bad genes everywhere, very quickly. Back to brother Mueller and his silver ratchet. Or was that Maxwell and his silver hammer? Can't remember.
Title: NO MORE OVERFLOW
Post by: Numsgil on April 12, 2005, 05:58:15 AM
Ah, see they don't teach this kind of thing in Bio 101.  I always knew we were playing with very specific cases with mutations.

One thing Paul, what do you mean by generational turnover?  I agree that speeding up mutations means that you need a way to speed up the removal of deleterious mutations from the population.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 12, 2005, 11:29:00 AM
Quote
"mutating bot" will lose. ?????

No Shvartz , I am saying "mutating bot" will win , win win ;.....
Title: NO MORE OVERFLOW
Post by: Light on April 12, 2005, 11:38:13 AM
Isn't generational turnover the average time it takes for one generation to die and another to take over, so for humans it would be like 70  or basically the lifespan of a bot. A high turnover would be a bot with a short lifespan
Title: NO MORE OVERFLOW
Post by: shvarz on April 12, 2005, 11:55:15 AM
Quote
No Shvartz , I am saying "mutating bot" will win , win win ;....


Then what is your problem then?  I don't get it...  If it works already, then why do you want to change something?  :)

Seriosly though, you are saying that bot that changes  mutation rates wins in your competition against a bot that does not change the mutation rates, right? And they both have mutation rates set by you...

I am saying that mutation rates that you set is probably too high, leading to accumulation of bad mutations.  So when a bot can change it's mutation rates, then it will select for bots with lower mutation rates, become more stable and win.  This is just a guess.  I would be able to tell you more if you gave more details.  A good test would be to take the bot that wins the competition and put it against the parental bots with mutations completely disabled.  If it loses or is even with parent, then I am right.  If it wins over the parent, then I am wrong and something else is going on.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 12, 2005, 12:00:08 PM
I just had this funny feeling... that changing the way 'mutation of mutation rates' works will make it even better, .... but I have my own Visual Basic for that.... I leave you guys alone, I need to test it myself first.


and sry for that c***BEEEP*****p yesturday, You alll....
Title: NO MORE OVERFLOW
Post by: Numsgil on April 12, 2005, 05:56:37 PM
I would just like to take this opportunity to say that if you're going to swear, by all means swear.  As long as you don't make it a habit, I don't mind.

What I do mind is ****beep*****.  Drives me crazy.  Just swear.
Title: NO MORE OVERFLOW
Post by: Botsareus on April 12, 2005, 06:50:30 PM
lol Num;



Ok I give up on improving  mutation rates of mutation rates for now, it did not work. You win guys!!!
Title: NO MORE OVERFLOW
Post by: Numsgil on April 12, 2005, 06:54:45 PM
It's not a contest.  No one can 'win' (except the li'l ones, the bots).
Title: NO MORE OVERFLOW
Post by: AZPaul on April 13, 2005, 04:28:36 AM
It is after midnight, must be time for DB Forum. This is what happens when you try to have "other lives."

Numsgil:
Quote
One thing Paul, what do you mean by generational turnover? I agree that speeding up mutations means that you need a way to speed up the removal of deleterious mutations from the population.

Light:
Quote
Isn't generational turnover the average time it takes for one generation to die and another to take over, so for humans it would be like 70 or basically the lifespan of a bot. A high turnover would be a bot with a short lifespan

Bingo!

Create a bot with a very short lifespan, turn up the mutation rate and PRESTO CHANGEO, instant evolutionary timescales!

Actually, this is more difficult than it appears since you must balance the lifespan with the mutation rates in such a way as to have a few mutations per generation while having enough lifespan to experience selective pressures thus testing the mutations.

Too high a mutation rate and the population mutates further before natural selection gets to do its selection thing in succeeding generations and may indeed mutate a good mutation right off the table before it can spread. Too short a lifespan and everybody dies of "old age" before natural selection gets to do its selection thing since the bot has no time to test the mutation by dodging predators or becoming more energy efficient prior to breeding before it dies.

Now that's a mouthful.

Anyway, depending upon the sim being attempted (mine being pressures of sexual selection criteria over lots and lots of generations, or atleast [you]would[/you] be if [begin hint] I had a working .sexrepro capability [end hint]) shortening lifespans and speeding up mutation rates can achieve much faster results. If I find the right balance I hope to cut a million cycles off my sims while maintaining the mutation rate per generation and the same number of generations. For me that's many hours of compute time.

BTW, the "Cambrian Explosion" of new phyla (including almost all present day body plans) lasted some 50+- million years. Paleontologists have a rather strange sense of time. Though considering the prior 4 billion years, I suppose 50 million can be considered as somewhat of a "short" period, right? Riiight.