Platypus
Platypus copied to clipboard
Inconsistency in return type for CMA-ES
Hi there. First, thanks for the library, and anything named after a monotreme can't be bad. I'm filing this ticket because I noticed an inconsistency in the return type for CMA-ES versus all the others.
One has to do something like this...
best_obj, best_x = feasible_solution_obj[0] if isinstance(best_x,FixedLengthArray): best_x = best_x._data # CMA-ES returns it this way for some reason
in order to enforce consistency across different algos. Perhaps this could be cleaned up? The change would simply be to return x._data in the feasible solution list in place of x.