Skip to content

Commit

Permalink
Add step dependencies for restart
Browse files Browse the repository at this point in the history
  • Loading branch information
cbegeman committed Jan 11, 2024
1 parent fc9ab6f commit c081067
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions polaris/ocean/tasks/ice_shelf_2d/default/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ def __init__(self, component, resolution, indir, init, config,
do_restart=True)
symlink = None
restart_step.set_shared_config(config, link='ice_shelf_2d.cfg')
restart_step.add_dependency(forward_step, forward_step.name)
self.add_step(restart_step, symlink=symlink)
self.add_step(Validate(component=component,
step_subdirs=['forward', 'restart'],
Expand Down
4 changes: 1 addition & 3 deletions polaris/ocean/tasks/ice_shelf_2d/forward.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,7 @@ def __init__(self, component, resolution, mesh, init,
work_dir_target=f'{init.path}/output.nc')
self.add_input_file(filename='graph.info',
work_dir_target=f'{mesh.path}/culled_graph.info')
if do_restart:
self.add_input_file(filename='restarts',
target='../forward/restarts')

self.add_output_file(
filename='output.nc',
validate_vars=['temperature', 'salinity', 'layerThickness',
Expand Down
1 change: 1 addition & 0 deletions polaris/ocean/tasks/ice_shelf_2d/forward.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ omega:
filename_template: init.nc
restart:
output_interval: 0000_00:00:01
filename_template: ../forward/restarts/restart.$Y-$M-$D_$h.$m.$s.nc
output:
type: output
filename_template: output.nc
Expand Down

0 comments on commit c081067

Please sign in to comment.