Skip to content

Commit

Permalink
added pool.close(), pool.join() stop mem leaks
Browse files Browse the repository at this point in the history
  • Loading branch information
jsadler2 committed Apr 11, 2019
1 parent 45dd8bc commit 523177b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions swmm_mpc/run_ea.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ def run_ea(work_dir, config_file, ga_params):
seed_next_population(hof[0], ga_params.get('nindividuals', 25),
sm.run.ctl_str_ids, pop_file, sm.run.n_ctl_steps)
min_cost = min(logbook.select("min"))
pool.close()
pool.join()
return hof[0], min_cost


Expand Down

0 comments on commit 523177b

Please sign in to comment.