From a5427a3bb6235301fcfea4391e74dd8cdf8ac778 Mon Sep 17 00:00:00 2001 From: Matteo De Carlo Date: Wed, 7 Aug 2019 19:37:38 +0200 Subject: [PATCH] cleanup program arguments part 3 fixes in the code: argument variables where read but not used, they are now removed --- experiments/examples/manager_pop.py | 1 - experiments/examples/watch_best_robots.py | 1 - experiments/karines_experiments/manager_pop.py | 1 - experiments/karines_experiments/manager_pop_lava.py | 1 - experiments/karines_experiments/watch_best_robots.py | 1 - pyrevolve/config.py | 5 +---- pyrevolve/evolution/population.py | 3 --- 7 files changed, 1 insertion(+), 12 deletions(-) diff --git a/experiments/examples/manager_pop.py b/experiments/examples/manager_pop.py index 4d0e37921b..ed42adced8 100755 --- a/experiments/examples/manager_pop.py +++ b/experiments/examples/manager_pop.py @@ -76,7 +76,6 @@ async def run(): offspring_size=offspring_size, experiment_name=settings.experiment_name, experiment_management=experiment_management, - measure_individuals=settings.measure_individuals, ) n_cores = settings.n_cores diff --git a/experiments/examples/watch_best_robots.py b/experiments/examples/watch_best_robots.py index 2aa5477409..935751dfaa 100755 --- a/experiments/examples/watch_best_robots.py +++ b/experiments/examples/watch_best_robots.py @@ -58,7 +58,6 @@ async def run(): offspring_size=50, experiment_name=settings.experiment_name, experiment_management=experiment_management, - measure_individuals=settings.measure_individuals, ) settings = parser.parse_args() diff --git a/experiments/karines_experiments/manager_pop.py b/experiments/karines_experiments/manager_pop.py index ceda08284e..2c82914acd 100755 --- a/experiments/karines_experiments/manager_pop.py +++ b/experiments/karines_experiments/manager_pop.py @@ -81,7 +81,6 @@ def fitness_function(robot_manager, robot): offspring_size=offspring_size, experiment_name=settings.experiment_name, experiment_management=experiment_management, - measure_individuals=settings.measure_individuals, ) settings = parser.parse_args() diff --git a/experiments/karines_experiments/manager_pop_lava.py b/experiments/karines_experiments/manager_pop_lava.py index be2f86b6d4..0d5ab20a5b 100755 --- a/experiments/karines_experiments/manager_pop_lava.py +++ b/experiments/karines_experiments/manager_pop_lava.py @@ -81,7 +81,6 @@ def fitness_function(robot_manager, robot): offspring_size=offspring_size, experiment_name=settings.experiment_name, experiment_management=experiment_management, - measure_individuals=settings.measure_individuals, ) settings = parser.parse_args() diff --git a/experiments/karines_experiments/watch_best_robots.py b/experiments/karines_experiments/watch_best_robots.py index 030f912200..5f84e81562 100755 --- a/experiments/karines_experiments/watch_best_robots.py +++ b/experiments/karines_experiments/watch_best_robots.py @@ -57,7 +57,6 @@ async def run(): offspring_size=50, experiment_name=settings.experiment_name, experiment_management=experiment_management, - measure_individuals=settings.measure_individuals, ) settings = parser.parse_args() diff --git a/pyrevolve/config.py b/pyrevolve/config.py index ef2c7f42da..2f22e1bd56 100644 --- a/pyrevolve/config.py +++ b/pyrevolve/config.py @@ -207,8 +207,5 @@ def make_revolve_config(conf): """ conf.enable_wheel_parts = False - conf.brain_conf = { - 'learner': conf.learner, - 'genome': conf.genome, - } + conf.brain_conf = {} return conf diff --git a/pyrevolve/evolution/population.py b/pyrevolve/evolution/population.py index 2c12a4faf2..d83d408bad 100644 --- a/pyrevolve/evolution/population.py +++ b/pyrevolve/evolution/population.py @@ -26,7 +26,6 @@ def __init__(self, evaluation_time, experiment_name, experiment_management, - measure_individuals, offspring_size=None, next_robot_id=1): """ @@ -45,7 +44,6 @@ def __init__(self, :param evaluation_time: duration of an experiment :param experiment_name: name for the folder of the current experiment :param experiment_management: object with methods for managing the current experiment - :param measure_individuals: weather or not to perform phenotypic measurements :param offspring_size (optional): size of offspring (for steady state) """ self.population_size = population_size @@ -63,7 +61,6 @@ def __init__(self, self.evaluation_time = evaluation_time self.experiment_name = experiment_name self.experiment_management = experiment_management - self.measure_individuals = measure_individuals self.offspring_size = offspring_size self.next_robot_id = next_robot_id