bout_runners.submitter.submitter_factory¶
Contains the submitter factory.
Functions
|
Return the processor split based on the submitter configuration file. |
|
Return the submission dict based on the submitter configuration file. |
|
Return a Submitter object. |
Infer the submitter and return appropriate positional and keyword arguments. |
|
Check if the PBS system is available. |
|
Check if the SLURM system is available. |
-
bout_runners.submitter.submitter_factory.
get_processor_split
(submitter_section: configparser.SectionProxy) → bout_runners.submitter.processor_split.ProcessorSplit[source]¶ Return the processor split based on the submitter configuration file.
- Parameters
- submitter_sectionconfigparser.SectionProxy
The section of the submitters configuration to use Must contain the section number_of_processors
- Returns
- ProcessorSplit
The processor split object
-
bout_runners.submitter.submitter_factory.
get_submission_dict
(cluster_section: configparser.SectionProxy) → Dict[str, Optional[str]][source]¶ Return the submission dict based on the submitter configuration file.
- Parameters
- cluster_sectionconfigparser.SectionProxy
The cluster section of the submitters configuration Must contain the sections walltime, account, queue, mail
- Returns
- submission_dictdict
Dictionary containing options for the submission_dict The submission_dict is a keyword parameter to the cluster constructors
See also
AbstractClusterSubmitter
Submitter object used for clusters
-
bout_runners.submitter.submitter_factory.
get_submitter
(name: Optional[str] = None, argument_dict: Optional[Dict[str, Any]] = None) → bout_runners.submitter.abstract_submitter.AbstractSubmitter[source]¶ Return a Submitter object.
- Parameters
- namestr or None
Name of the submitter to use If None the submitter will be inferred
- argument_dictdict
Dict containing positional and keyword arguments
- Returns
- submitterAbstractSubmitter
The implemented submitter class
- Other Parameters
- The following parameters can be given argument_dict
- processor_splitProcessorSplit or None
Object containing the processor split Used for all submitters
- run_pathPath or str or None
Positional argument Directory to run the command from Used in LocalSubmitters
- job_namestr or None
Positional argument Name of the job Used for cluster submitters
- store_directorypath or None
Keyword agrument Directory to store the scripts Used for cluster submitters
- submission_dictNone or dict of str of None or str
Keyword agrument Dict containing optional submission options One the form
>>> {'walltime': None or str, ... 'account': None or str, ... 'queue': None or str, ... 'mail': None or str}
These options will not be used if the submission_dict is None Used for cluster submitters
- Raises
- ValueError
If the input does not match the desired submitter
- NotImplementedError
If the name is not a supported submitter class
-
bout_runners.submitter.submitter_factory.
infer_submitter
() → Tuple[str, Dict[str, Any]][source]¶ Infer the submitter and return appropriate positional and keyword arguments.
- Returns
- namestr
Name of the submitter type
- argument_dictdict
Dict containing positional and keyword arguments