Skip to content

HELP WANTED: Agility of availableCores() #17

@HenrikBengtsson

Description

@HenrikBengtsson

parallelly::availableCores() returns the number of cores available for multicore processing. R itself provides parallel::detectCores() for this. There is also the mc.cores option (default to environment variable MC_CORES) set when parallel is loaded. Beyond this, various systems/setups set specific environment variables to reflect the number of available/allocated cores. For instance, resource manager PBS, sets environment variable PBS_NUM_PPN on the compute node specifying the number of allotted cores.

Currently, availableCores() defaults to return the first valid value of (in order):

  1. PBS_NUM_PPN
  2. mc.cores (and MC_CORES)
  3. parallel::detectCores()

I would like to add support for more resource/workload managers and other distributed processing environments. For instance,

What else am I missing?

  • BBS_HOME - (env var) if set (to anything) BiocParallel will "throttle number of cores used on Bioconductor build systems [...] to 4".
  • snowFT's ./.clustersize file that specifies number of workers?

I appreciate any feedback on what environment variables or commands that are available to a compute node to query the number of allotted cores, iff at all. Please try to provide links to documentations if you can.

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions