def special_role_parameters(cls, role, job_parameters: RunParameters): if role == "arbiter": job_parameters.task_parallelism = 1 if job_parameters.adaptation_parameters["task_nodes"] > 0: job_parameters.adaptation_parameters["task_nodes"] = 1 if job_parameters.adaptation_parameters["task_cores_per_node"] > 0: job_parameters.adaptation_parameters["task_cores_per_node"] = 1
def adapt_job_parameters(cls, role, job_parameters: RunParameters, create_initiator_baseline=False): ResourceManager.adapt_engine_parameters(role=role, job_parameters=job_parameters, create_initiator_baseline=create_initiator_baseline) if create_initiator_baseline: if job_parameters.task_parallelism is None: job_parameters.task_parallelism = DEFAULT_TASK_PARALLELISM if job_parameters.federated_status_collect_type is None: job_parameters.federated_status_collect_type = DEFAULT_FEDERATED_STATUS_COLLECT_TYPE if create_initiator_baseline and not job_parameters.computing_partitions: job_parameters.computing_partitions = job_parameters.adaptation_parameters["task_cores_per_node"] * job_parameters.adaptation_parameters["task_nodes"]
def adapt_job_parameters(cls, job_parameters: RunParameters): if job_parameters.task_parallelism is None: job_parameters.task_parallelism = DEFAULT_TASK_PARALLELISM if job_parameters.federated_status_collect_type is None: job_parameters.federated_status_collect_type = DEFAULT_FEDERATED_STATUS_COLLECT_TYPE ResourceManager.job_engine_support_parameters(job_parameters=job_parameters)