Skip to content

Commit

Permalink
Set number of tasks for PALS mpiexec (#247)
Browse files Browse the repository at this point in the history
Correction to flag setting number of tasks for PalsMpiexecSettings

[ committed by @rickybalin ]
[ reviewed by @MattToast, @ashao ]
  • Loading branch information
rickybalin authored Jan 18, 2023
1 parent ff2cf24 commit 473566f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion smartsim/settings/mpirunSettings.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,4 @@
"mpirunSettings will be deprecated; use mpiSettings instead.",
DeprecationWarning,
stacklevel=2
)
)
8 changes: 8 additions & 0 deletions smartsim/settings/palsSettings.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,14 @@ def set_cpu_binding_type(self, bind_type):
"""
self.run_args["cpu-bind"] = str(bind_type)

def set_tasks(self, tasks):
"""Set the number of tasks
:param tasks: number of total tasks to launch
:type tasks: int
"""
self.run_args["np"] = int(tasks)

def set_tasks_per_node(self, tasks_per_node):
"""Set the number of tasks per node
Expand Down

0 comments on commit 473566f

Please sign in to comment.