giacomelli / GeneticSharp

GeneticSharp is a fast, extensible, multi-platform and multithreading C# Genetic Algorithm library that simplifies the development of applications using Genetic Algorithms (GAs).
MIT License
1.26k stars 330 forks source link

Can we identify which Chromosome is which? #115

Closed gkapellmann closed 8 months ago

gkapellmann commented 9 months ago

So, I might be designing my project wrong, but I want to identify which chromosome is which so that the fitness function can be adjusted accordingly?

I am using Unity, so there is the complication. Basically, I created some race cars, each has acceleration, steering and 3 sensor weights. Each car has to pass through 5 stages in the track and has its own time. If the car crashes with a wall, it is destroyed automatically.

I want to take into account the amount of stages reached and the time the car is alive, but to do this I should be able to identify the chromosome used when being evaluated.

Does this make sense?

gkapellmann commented 8 months ago

While I don't know if I got no answer because of being forgotten or kindness (I was too slow to discover that this is totally possible by adding my own id's to the chromosome class). I have now understood that this is totally doable, and therefore no need to have this issue open.

I have a different question, which I'll post in a different issue.

Thank for the lib, is very good!