Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chicoma debug #859

Merged
merged 2 commits into from
Sep 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion compass/job/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,11 @@ def write_job_script(config, machine, target_cores, min_cores, work_dir,
else:
constraint = ''

if config.has_option('job', 'reservation'):
reservation = config.get('job', 'reservation')
else:
reservation = ''

job_name = config.get('job', 'job_name')
if job_name == '<<<default>>>':
if suite == '':
Expand All @@ -96,7 +101,8 @@ def write_job_script(config, machine, target_cores, min_cores, work_dir,
text = template.render(job_name=job_name, account=account,
nodes=f'{nodes}', wall_time=wall_time, qos=qos,
partition=partition, constraint=constraint,
suite=suite, pre_run_commands=pre_run_commands,
reservation=reservation, suite=suite,
pre_run_commands=pre_run_commands,
post_run_commands=post_run_commands)
text = _clean_up_whitespace(text)
if suite == '':
Expand Down
3 changes: 3 additions & 0 deletions compass/job/job_script.template
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
{% if qos != '' -%}
#SBATCH --qos={{ qos }}
{%- endif %}
{% if reservation != '' -%}
#SBATCH --reservation={{ reservation }}
{%- endif %}
{% if partition != '' -%}
#SBATCH --partition={{ partition }}
{%- endif %}
Expand Down
3 changes: 3 additions & 0 deletions compass/machines/chicoma-cpu.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,8 @@ threads_per_core = 1
# The job partition to use
partition = standard

# The job reservation to use (needed for debug jobs)
reservation =

# The job quality of service (QOS) to use
qos = standard
19 changes: 19 additions & 0 deletions docs/developers_guide/machines/chicoma.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,22 @@ Then, you can build the MPAS model with
.. code-block:: bash

make [DEBUG=true] gnu-cray

debug jobs
~~~~~~~~~~

In order to run jobs in the debug queue, you will need to use:

.. code-block:: cfg

# Config options related to creating a job script
[job]

# The job partition to use
partition = debug

# The job reservation to use (needed for debug jobs)
reservation = debug

# The job quality of service (QOS) to use
qos =
7 changes: 5 additions & 2 deletions docs/users_guide/machines/chicoma.rst
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,12 @@ when setting up test cases or a test suite:
# The job partition to use
partition = standard
# The job reservation to use (needed for debug jobs)
reservation =
# The job quality of service (QOS) to use
qos = standard
Additionally, some relevant config options come from the
`mache <https://github.com/E3SM-Project/mache/>`_ package:
Expand Down Expand Up @@ -213,4 +216,4 @@ To build the MPAS model with

.. code-block:: bash
make [DEBUG=true] [OPENMP=true] [ALBANY=true] gnu-cray
make [DEBUG=true] [OPENMP=true] [ALBANY=true] gnu-cray
Loading