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

Global option for parallel processing #156

Open
zkamvar opened this issue Oct 15, 2016 · 7 comments
Open

Global option for parallel processing #156

zkamvar opened this issue Oct 15, 2016 · 7 comments
Assignees

Comments

@zkamvar
Copy link
Collaborator

zkamvar commented Oct 15, 2016

Right now for anything dealing with genlight objects, parallel processing is dependent on whether or not the package parallel is installed:

glSim(..., parallel = require("parallel"))

It can be a pain to specify parallel = FALSE for all the functions when dealing with genlight. I propose to add a global option adegenet.parallel to be set when the package is loaded in a similar fashion to dplyr: https://github.com/hadley/dplyr/blob/master/R/zzz.r

This way, the checking could be done with the option, as opposed to loading the parallel package:

options(adegenet.parallel = FALSE)
glSim(..., parallel = getOption("adegenet.parallel"))

I'm just putting this here so I can open a pull request later 😄

@zkamvar zkamvar self-assigned this Oct 15, 2016
@thibautjombart
Copy link
Owner

Great idea :)

@thierrygosselin
Copy link
Collaborator

I thought parallel was installed automatically now with R ?

@romunov
Copy link
Collaborator

romunov commented Jan 4, 2017

@thierrygosselin it's not a matter of installing the package but passing parameters to various functions.

@zkamvar
Copy link
Collaborator Author

zkamvar commented Jan 4, 2017

@thierrygosselin, there have been a history of problems with parallel on windows, but the main issue this would fix is testing on clusters (as was brought up in #128).

@thierrygosselin
Copy link
Collaborator

Ha ! ok great!

@thibautjombart
Copy link
Owner

I can't remember: has this been implemented - shall I close the issue?

@zkamvar
Copy link
Collaborator Author

zkamvar commented Jan 9, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants