polaris.ModelStep.set_model_resources
- ModelStep.set_model_resources(ntasks=None, min_tasks=None, openmp_threads=None, gpus=None, min_gpus=None, gpus_per_task=None, min_gpus_per_task=None, memory=None, min_memory=None)[source]
Update the resources for the step. This can be done within init,
setup()orruntime_setup()for the step that this step belongs to, or init,configure()orrun()for the task that this step belongs to.- Parameters:
ntasks (int, optional) – the number of tasks the step would ideally use. If too few cores are available on the system to accommodate the number of tasks and the number of cores per task, the step will run on fewer tasks as long as as this is not below
min_tasksmin_tasks (int, optional) – the number of tasks the step requires. If the system has too few cores to accommodate the number of tasks and cores per task, the step will fail
openmp_threads (int, optional) – the number of OpenMP threads to use
gpus (int, optional) – the number of GPUs to use, as a total for the step rather than a count per task
min_gpus (int, optional) – the minimum number of GPUs required, again as a total
gpus_per_task (int, optional) –
the number of GPUs per task to use
Deprecated since version 1.1.0: Use
gpusinsteadmin_gpus_per_task (int, optional) –
the minimum number of GPUs per task required
Deprecated since version 1.1.0: Use
min_gpusinsteadmemory (int, optional) – the amount of memory in MB the step would ideally be given
min_memory (int, optional) – the amount of memory in MB the step needs in order to run at all