From effe5aaaef1964d85609b52d4b2d944d94b2dbd0 Mon Sep 17 00:00:00 2001 From: "Matthew R. Becker" Date: Sun, 26 Feb 2023 06:04:08 -0600 Subject: [PATCH] BUG compute number of LSF slots properly --- mattspy/lsf_yield.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mattspy/lsf_yield.py b/mattspy/lsf_yield.py index 3ce4189..6f23813 100644 --- a/mattspy/lsf_yield.py +++ b/mattspy/lsf_yield.py @@ -6,6 +6,7 @@ import atexit import logging import time +import math from concurrent.futures import ThreadPoolExecutor, as_completed from .yield_result import ParallelResult, ParallelSubmissionError @@ -97,7 +98,7 @@ def _submit_lsf_job(*, subid, job_data, mem, execid, timelimit, execdir): # compute mem requirement if mem > 4: mem_str = " span[hosts=1]" - n = 2 + n = math.ceil(mem/4) else: n = 1 mem_str = ""