Skip to content

Commit

Permalink
first draft packing nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
daues committed Dec 5, 2023
1 parent e3d61e8 commit 6336508
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
7 changes: 7 additions & 0 deletions python/lsst/ctrl/execute/allocatorParser.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,13 @@ def parseArgs(self, basename):
default=None,
help="glide-in inactivity shutdown time in seconds",
)
parser.add_argument(
"-p",
"--pack",
action="store_true",
dest="packnodes",
help="encouraging nodes to pack jobs rather than spread",
)
parser.add_argument(
"-v", "--verbose", action="store_true", dest="verbose", help="verbose"
)
Expand Down
5 changes: 5 additions & 0 deletions python/lsst/ctrl/execute/slurmPlugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,11 @@ def loadSlurm(self, name, platformPkgDir):
self.allocationFileName
)

if self.opts.packnodes is None:
self.defaults["PACK_BLOCK"] = "#"
else:
self.defaults["PACK_BLOCK"] = "Rank = TotalCpus - Cpus"

Check failure on line 143 in python/lsst/ctrl/execute/slurmPlugin.py

View workflow job for this annotation

GitHub Actions / call-workflow / lint

W291

trailing whitespace

# handle dynamic slot block template:
# 1) if it isn't specified, just put a comment in it's place
# 2) if it's specified, but without a filename, use the default
Expand Down

0 comments on commit 6336508

Please sign in to comment.