diff --git a/slurm-eff-tool.py b/slurm-eff-tool.py index fadaba5..3953dca 100755 --- a/slurm-eff-tool.py +++ b/slurm-eff-tool.py @@ -751,7 +751,7 @@ def make_single_row(rec: JobRecord, dflt_mpcpu: float) -> OutputRow: waste_mem = max(0,walltime * (100-rec.mem_eff)/100 \ * (rec.reqmem_gb - rec.cpus * dflt_mpcpu)) - waste_cpu=None + waste_cpu = None if rec.cpu_eff is not None: waste_cpu = walltime * (100-rec.cpu_eff) * rec.cpus @@ -814,7 +814,7 @@ def make_aggregate_row(records: list[JobRecord], username: str, waste_cpu=None if cpu_efficiency is not None and walltime is not None: - waste_cpu = walltime * (100-cpu_efficiency) * first.cpus + waste_cpu = count * walltime * (100-cpu_efficiency) * first.cpus return OutputRow( username=username,