Naquad
unread,Jan 14, 2025, 6:49:58 AMJan 14Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to deap-users
Hi all,
I’m currently working on a complex Genetic Programming (GP) problem that has strict explainability requirements. To meet these requirements, I’ve introduced a type system to ensure type semantics are preserved. However, I’ve encountered an issue related to multiple registrations of the same function. Specifically, when I add the same function multiple times to the primitive set with different arguments but the same return type (e.g., comparison operators returning booleans), these functions begin to dominate the trees. This behavior makes sense, as the probability of selecting one of the variants increases with their presence.
In his paper on Strongly Typed Genetic Programming, Montana suggests introducing a generic function similar to C++’s overloading or Python’s single dispatch functionality (from functools module). This approach resolves the issue by allowing the addition of the same function with different arguments and the same return type without skewing the probabilities.
I noticed that DEAP does not natively support this functionality. Before diving into the DEAP code to implement and override these features (which at the first glance is going to be a lot), I wanted to ask:
Are there any existing methods or approaches in DEAP to implement generics or control the selection probabilities of specific functions?
Thank you.