AureumChaos / LEAP

A general purpose Library for Evolutionary Algorithms in Python.
Academic Free License v3.0
83 stars 19 forks source link

Resolve expected vs. probability for mutation ops #26

Open markcoletti opened 4 years ago

markcoletti commented 4 years ago

Mutation operators take on an expected parameter that dictates the "expected" number of mutations per individual. Jeff pointed out that there may be scenarios where someone would prefer to specify the probability, instead. However, clearly "expected" and "probability" are mutually exclusive, and so steps would have to be taken in the design of these mutation operators to ensure that users don't accidentally misuse them by specifying both parameters.

markcoletti commented 4 years ago

I had posed some possibilities:

The simplest would be the first, but that feels kind of like a kludge. The second is more elegant, but adds some complexity. The third was added more for completeness as I think it's the worst of the three. :(

SigmaX commented 1 year ago

ex. Gaussian mutation doesn't have a p_mutate parameter.