Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding pool.close and pool.join calls to ensure processes are properly closed. #1

Merged
merged 2 commits into from Dec 19, 2017

Conversation

jmoore52
Copy link
Contributor

Processes aren't properly closed after the algorithm runs. When running multiple GA executions in a loop, the OS will eventually hit the limit for number of processes. No Bueno.

This quick fix works and explicitly closes processes after the algorithm has run.

Adding pool.close and pool.join calls to ensure processes are properly closed.

Processes aren't properly closed after the algorithm runs. When running multiple GA executions in a loop, the OS will eventually hit the limit for number of processes. No Bueno. 

This quick fix works and explicitly closes processes after the algorithm has run. 

Adding pool.close and pool.join calls to ensure processes are properly closed.
@manuel-calzolari
Copy link
Owner

Can you add the statement if self.n_jobs != 1:?

Thank you for your contribution.

Adding check for multiprocessing
@manuel-calzolari manuel-calzolari changed the title Update __init__.py Adding pool.close and pool.join calls to ensure processes are properly closed. Dec 19, 2017
@manuel-calzolari manuel-calzolari merged commit d981a6c into manuel-calzolari:master Dec 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants