Bots and Simulations > Evolution and Internet Sharing Sims
First Evosim
The_Duck:
Hi all,
I've started up my first real attempt at a long-term evosim. I'd appreciate any suggestions about parameters and such to encourage evolution.
Details:
-I am trying to evolve Animal Minimalis. Any other suggestions for a simple bot to evolve?
-The food chain is Alga Minimalis -> Animal Minimalis -> Shepherd bot.
-Sim size = 4
-The shepherd is handcoded, virus/mutation immune, omnivorous, and much better than Animal Minimalis; a cond for all genes is "*.totalbots *.totalmyspecies div 4 >" so that it hibernates when it is too large a percentage of the total population.
Shepherd code:
[div class=\'codetop\']CODE[div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']'all genes (except for birth-tie breaking) predicated on .totalbots / .totalmyspecies
cond
*.robage 0 =
start
.tie inc
314 628 rnd add .aimdx store
stop
cond
*.robage 1 =
*.numties 0 > or
start
*.tiepres .deltie store
stop
cond
*.nrg 4000 >
*.totalbots *.totalmyspecies div 4 >
start
50 .repro store
stop
cond
*.totalbots *.totalmyspecies div 4 >
start
5 .up store
*.nrg 4 div .strbody store
*.body 2 div .fdbody store
.shoot .vloc store
0 .venval store
*.velscalar 40 >
314 rnd .aimdx store
stop
cond
*.totalbots *.totalmyspecies div 4 >
*.nrg 500 >
*.venom 100 <
start
10 .strvenom store
stop
cond
*.totalbots *.totalmyspecies div 4 >
*.eye5 0 >
*.refeye *.myeye !=
start
*.refveldx .dx store
*.refvelup 80 add .up store
*.eye6 *.eye4 sub *.eye4 *.eye6 sub abs div 5 mult .aimdx store
stop
cond
*.totalbots *.totalmyspecies div 4 >
*.eye5 50 >
*.refeye *.myeye !=
start
*.refveldx .dx store
*.refvelup .up store
*.eye6 *.eye4 sub *.eye4 *.eye6 sub abs div 5 mult .aimdx store
.shoot dec
'sometimes shoot venom
10 rnd 1 =
-3 .shoot store
*.venom .shootval store
stop
cond
*.totalbots *.totalmyspecies div 4 >
*.eye5 0 =
*.refeye *.myeye = or
*.shflav 0 !=
*.shflav -2 !=
start
*.shang 314 add .aimdx store
stop
end
------------
I am trying to get smooth, regular predator-prey cycles going between Animal Minimalis and Alga Minimalis. I have veg population capped at 100; Currently the Animals will slowly overpopulate the sim while the Alga population stays stuck to the ceiling; then suddenly the Alga population crashes and the Animal population declines slowly, until suddenly Alga populations surge again, and so on. I want a smoother cycle; I guess the problem is that the delay between Animal and Alga populations is too long. I was thinking a well-tuned constant tax on nrg for Animals might help; it would make the Animals die off more quickly when their food source disappears. Also I might uncap the veg population. Any thoughts?
Actually it looks like the population stabilized with the algae at the population cap and Animal Minimalis at the shepherd in equilibrium. I don't like the veggie population sitting at the cap, so I uncapped it; veggie population is now 1000 and rising. I guess I'll play around with the energy fed to veggies to stabilize them.
A problem with the shepherd is that .totalbots includes veggies, so that it starts playing rough with Animal Minimalis when veggie populations spike. I think this delays the restoring force that would otherwise be applied to spiking veggie populations. Also the shepherd's venom disarms its target for a while, making it harder for Animal Minimalis to control the veggies.
I'd appreciate any help, and I'll report any interesting results here.
EricL:
Sounds interesting. I prefer starting from zerobots personally since msot hand authorred DNA usueally must devolve before it can evolve. It will be interesting to see whether Animal_Min maintains it's functionality or not. Preditors may force it to.
Some suggestions:
1) Post the sim. That would be very helpful fin understanding all the settings, whether your alga's are allowed to mutate, etc.
2) You could code your shepards to target only the Animals if you wanted by having them ignore bots with that exact dnalen or fixed bots (if they are fixed) or similar.
3) Adding some randomness to when your shepards wake up witllsmooth things out. See this topic.
4) Consider having your shepards commit suicide when too large a percentage of the population. Again, add some randomness here so they don't all wink out in the same cycle.
Keep us posted...
Numsgil:
Partly the issue you have is that your population sizes are small. Or at least your veggy pop is too small. I'm thinking if you want to maintain a small population for speed reasons, make veggies more like trees:
1. Give them some minor defensive ability when they're being fed on. Maybe switch animal minimalis to -6 shots, and have veggy pain trigger shell production.
2. Fix veggies that are above a certain size.
3. Feed veggies based on kilobody, instead of just per instance.
4. Have you veggies wander a bit before settling down.
5. Have stable shelled veggies produce lots of little babies. Something like 2 or 3 percent. These are the seeds that go off and produce new "trees".
This way, each stable veggy is huge, more like a cluster of veggies, and you get the large nrg reserve of a group of traditional veggies.
shvarz:
Good advice above, I'll just throw in my two cents:
Keep the population well-mixed (low friction), this will smooth out any stochastic spikes in populations.
Don't use caps on veggie population. This creates an uneven flow of energy, veggies reach that cap and then they grow well above the size they would grow otherwise. This gives hunters that find them too much energy and hunters population spikes. Key to good smooth curves is self-control of the sim energy.
Track average energy and total energy of each species, this will help you figure out what causes unbalances.
You also need to pick veggie-predator pair that matches each other. Alga minimalis and Animal minimalis are a good start. Don't pick any predators that are too good.
Having the third species to hunt the Alga minimalis is a real pain. I spent quite a lot of time trying to work this out and had to give up eventually. It's possible to keep them all together for some time, but don't expect nice curves. Also, population sizes (and fields) for 3-way sims have to be pretty large. At smaller sizes stochastic effects are too great and one of the species eventually dies out.
The_Duck:
Thanks for the advice, guys. I've discovered, as shvarz noted, that it's hard to keep 3 species in a sim in balance for a long time. One of them usually dies out; maybe my predator-shepherd just isn't good enough. I decided to leave out the shepherd and just try to get a basic stable sim going, with just Alga Minimalis and Animal Minimalis. I still found it hard to keep things stable, so I decided to use the day/night feature: I give the veggies lots of energy but cut it off when total sim nrg rises is above certain threshold. Essentially this enforces conservation of nrg: any nrg lost to the sim is immediately returned as sunlight. This was inspired by my experiences with Gene Pool, which conserves energy and consistently produces stable predator-prey cycles. I also have a significant nrg tax on the bots just for being alive, which increases with age; this kills off bots that just sit around and provides selection pressure towards better hunters. I have mutations at 16x for 1 cycle out of 10 and 1/16x for the rest. I'll let it run for a while and might try to introduce a predator if things look stable enough.
The sim is attached; if you run it you'll note that in the absence of any friction the whole sim has developed a net momentum in the southwestwards direction. I'll be interested to see if this changes over time. Also, I noticed a few bots at one point with a broken conspec-avoidance gene, but it was the long-distance closing gene, not the shooting gene. I can see though how easy it is to break conspec-recognition with just a single point-mutation. I expect it will happen soon.
Navigation
[0] Message Index
[#] Next page
Go to full version