jade.jobs.job_submitter.JobSubmitter

class jade.jobs.job_submitter.JobSubmitter(config_file, output, is_new)[source]

Bases: JobManagerBase

Submits jobs for execution locally or on an HPC.

Internal constructor. Callers should use create() or load().

Methods

cancel_jobs(cluster)

Cancel running and pending jobs.

create(config[, output])

Creates a new instance.

find_error_log_messages(directory)

Parse output log files for error messages

generate_reports(directory, ...)

Create reports summarizing the output results of a set of jobs.

get_batch_post_process_config()

Get the batch post-process config data

get_completed_results()

Get results of completed jobs.

get_num_jobs()

Get the number of jobs to execute.

get_results_summmary()

Get a job results.

get_results_summmary_report()

Get a summary of job results in text form.

load(output)

Loads an instance from an existing directory.

run_checks()

Checks the configuration for errors.

run_submit_jobs(config, output[, local, ...])

Allows submission from an existing Python process.

submit_jobs(cluster[, force_local])

Submit simulations.

write_results_summary(filename, missing_jobs)

Write the results to filename in the output directory.

Attributes

config

classmethod create(config, output='output')[source]

Creates a new instance.

Parameters:
classmethod load(output)[source]

Loads an instance from an existing directory.

cancel_jobs(cluster)[source]

Cancel running and pending jobs.

submit_jobs(cluster, force_local=False)[source]

Submit simulations. Auto-detect whether the current system is an HPC and submit to its queue. Otherwise, run locally.

Parameters:
  • cluster (Cluster)

  • force_local (bool) – If on HPC, run jobs through subprocess as if local.

Return type:

Status

write_results_summary(filename, missing_jobs)[source]

Write the results to filename in the output directory.

static find_error_log_messages(directory)[source]

Parse output log files for error messages

Parameters:

directory (str) – output directory

static generate_reports(directory, resource_monitor_type)[source]

Create reports summarizing the output results of a set of jobs.

Parameters:
run_checks()[source]

Checks the configuration for errors. May mutate the config.

get_batch_post_process_config()

Get the batch post-process config data

get_completed_results()

Get results of completed jobs.

Return type:

list of Result

get_num_jobs()

Get the number of jobs to execute.

Return type:

int

get_results_summmary()

Get a job results.

Return type:

dict

get_results_summmary_report()

Get a summary of job results in text form.

Return type:

str

static run_submit_jobs(config, output, local=False, dry_run=False, pipeline_stage_num=None)[source]

Allows submission from an existing Python process.