source:
branches/2013/dev_r3987_UKMO4_OBS/NEMOGCM/TOOLS/OBSTOOLS/OOO/ooo/run.py
@
4528
Last change on this file since 4528 was 4140, checked in by andrewryan, 11 years ago | |
---|---|
File size: 555 bytes |
Rev | Line | |
---|---|---|
[4122] | 1 | """ |
2 | ||
3 | The NEMO offline observation operator is built and runs similarly to the | |
4 | online NEMO model. | |
5 | ||
6 | """ | |
7 | import subprocess | |
[4140] | 8 | import shlex |
[4127] | 9 | import os |
10 | ||
11 | class SubmitError(Exception): | |
12 | pass | |
13 | ||
[4140] | 14 | def submit(command="./opa"): |
[4122] | 15 | """Simple function that runs the code. |
16 | ||
17 | This can be customised based on the particular environment | |
18 | used to submit MPI or serial tasks. For simplicity, this | |
19 | function calls opa. | |
20 | ||
21 | By default, this program runs ``./opa``. | |
22 | ||
23 | :returns: retcode | |
24 | """ | |
[4140] | 25 | retcode = subprocess.call(shlex.split(command)) |
[4122] | 26 | return retcode |
27 |
Note: See TracBrowser
for help on using the repository browser.