Classes to configure and launch jobs from a wmt-exe environment.
wmtexe.launcher.BashLauncher(sim_id, server_url=None, launch_dir='~/.wmt', extra_args=[])[source]¶Bases: wmtexe.launcher.Launcher
WMT job launcher for a bash environment.
Methods
after_launch(**kwds) |
Perform actions after launching job. |
after_success(**kwds) |
Perform actions after job completes. |
before_launch(**kwds) |
Perform actions before launching job. |
launch(**kwds) |
Launch job with launch command. |
launch_command(**kwds) |
The command that runs a job. |
prepend_path() |
Places the bin directory of executor at the front of the path. |
run(**kwds) |
Perform job setup, launch, and teardown actions. |
script(**kwds) |
Generate the launch script. |
slave_command([extra_args]) |
Create the wmt-slave command. |
wmtexe.launcher.Launcher(sim_id, server_url=None, launch_dir='~/.wmt', extra_args=[])[source]¶Bases: object
Job launcher for a wmt-exe environment.
| Parameters: | sim_id : str
server_url : str or None, optional
launch_dir : str, optional
extra_args : list, optional
|
|---|
Attributes
| launch_dir | (str) The working directory from which the job is started. |
| script_path | (str) Path to launch script. |
| sim_id | (str) A unique UUID for the job. |
| server_url | (str or None) The URL of the WMT API server from which the job was submitted. |
Methods
after_launch(**kwds) |
Perform actions after launching job. |
after_success(**kwds) |
Perform actions after job completes. |
before_launch(**kwds) |
Perform actions before launching job. |
launch(**kwds) |
Launch job with launch command. |
launch_command(**kwds) |
The command that runs a job. |
run(**kwds) |
Perform job setup, launch, and teardown actions. |
script(**kwds) |
Generate the launch script. |
slave_command([extra_args]) |
Create the wmt-slave command. |
after_launch(**kwds)[source]¶Perform actions after launching job.
| Parameters: | **kwds
|
|---|
after_success(**kwds)[source]¶Perform actions after job completes.
| Parameters: | **kwds
|
|---|
before_launch(**kwds)[source]¶Perform actions before launching job.
| Parameters: | **kwds
|
|---|
launch(**kwds)[source]¶Launch job with launch command.
| Parameters: | **kwds
|
|---|
launch_command(**kwds)[source]¶The command that runs a job.
| Parameters: | **kwds
|
|---|---|
| Returns: | str
|
run(**kwds)[source]¶Perform job setup, launch, and teardown actions.
| Parameters: | **kwds
|
|---|
wmtexe.launcher.QsubLauncher(sim_id, server_url=None, launch_dir='~/.wmt', extra_args=[])[source]¶Bases: wmtexe.launcher.Launcher
WMT job launcher for a PBS scheduler.
Methods
after_launch(**kwds) |
Perform actions after launching job. |
after_success(**kwds) |
Perform actions after job completes. |
before_launch(**kwds) |
Perform actions before launching job. |
launch(**kwds) |
Launch job with launch command. |
launch_command(**kwds) |
Path to launch script. |
run(**kwds) |
Perform job setup, launch, and teardown actions. |
script(**kwds) |
Generate the launch script. |
slave_command([extra_args]) |
Create the wmt-slave command. |
wmtexe.launcher.SbatchLauncher(*args, **kwds)[source]¶Bases: wmtexe.launcher.Launcher
WMT job launcher for a Slurm scheduler.
| Parameters: | sim_id : str
server_url : str or None, optional
launch_dir : str, optional
extra_args : list, optional
|
|---|
Attributes
| launch_dir | (str) The working directory from which the job is started. |
| script_path | (str) Path to launch script. |
| run_script_path | (str) Path to run script, which submits launch script to scheduler. |
| sim_id | (str) A unique UUID for the job. |
| server_url | (str or None) The URL of the WMT API server from which the job was submitted. |
Methods
after_launch(**kwds) |
Perform actions after launching job. |
after_success(**kwds) |
Perform actions after job completes. |
before_launch(**kwds) |
Perform actions before launching job. |
launch(**kwds) |
Launch job with launch command. |
launch_command(**kwds) |
The command that runs a job. |
run(**kwds) |
Perform job setup, launch, and teardown actions. |
run_script(**kwds) |
Generate the run script that submits job to scheduler. |
script(**kwds) |
Generate the launch script. |
slave_command([extra_args]) |
Create the wmt-slave command. |
before_launch(**kwds)[source]¶Perform actions before launching job.
| Parameters: | **kwds
|
|---|
launch(**kwds)[source]¶Launch job with launch command.
Note that we override Launcher.launch because we want to inherit the environment from the current process.
| Parameters: | **kwds
|
|---|