A recent addition to Clojush is the ability to have meta-error values along with the normal error values. The idea of meta-errors is that they are used during selection just like normal errors, but they aren’t taken into consideration when determining whether a program is a solution to a problem.
An example will help illustrate the utility of meta-errors. Let’s say you want to include the size of a program as an error value (or “test case”) that should be minimized. This seems like a potentially interesting thing to do, especially when using lexicase selection, where the size will just be one extra test case. But, when Clojush is determining whether a program solves a problem, we don’t care about the size error value – in fact, that value should never be zero, so if we included it in our “do we have a solution” check, we would never find a solution. So, we can include it as a meta-error, which will allow us to use size in parent selection, but not in checking for solutions.
In the Clojush implementation of meta-errors, a meta-error can be one of two things:
- A keyword for a built-in meta-error category, which at the time of writing includes the following:
- :size (minimize size of program)
- :compressibility (minimize amount a program compresses compared to itself) (NOTE: Not yet implemented)
- :total-error (minimize total error)
- :unsolved-cases (maximize number of cases with zero error)
- :rand (a random floating-point value)
- :rand-bit (randomly 0 or 1)
- :age (minimize genealogical age of program)
- A function that takes an individual and an argmap and returns a meta error value.