Closed schrum2 closed 2 years ago
Added FITNESS_FUNCTION
as a command line parameter, and it only checks if the string passed exists if INTERACTIVE_EVOLUTION
is false. I am going to go ahead and close this issue for now just because it seems like issue #41 expands on what was done with this issue.
Check that the fitness function is valid in main.py after it is loaded, and give a "nice" error message instead of a crash
Now there is a try/except block to display a nicer message ('____ is not a valid fitness function name.') when a invalid fitness function name is used.
Once #38 is complete, make a command line parameter
FITNESS_FUNCTION
that allows the user to specify the fitness function from the command line. We want this to be as general as possible. The type of the parameter will be string, but what we want is to have a way of taking that string and converting it into the Python function. We will require that any designated fitness function exist inside of thefitness_functions
module. You might have to look around on how to get a Python function given its name as a string.