Skip to content

Commit

Permalink
fix: wfbench.py gets mem in megabytes
Browse files Browse the repository at this point in the history
  • Loading branch information
ftschirpke committed Nov 20, 2023
1 parent c0ede14 commit 43ca19d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion wfcommons/wfbench/bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def create_benchmark_from_synthetic_workflow(
)
task.cores = task_cores + 1
if task_memory:
task.memory = task_memory
task.memory = task_memory * 1024 * 1024 # megabytes to bytes

# create data footprint
for task in self.workflow.tasks.values():
Expand Down
6 changes: 4 additions & 2 deletions wfcommons/wfbench/wfbench.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,10 @@ def main():

print(f"[WfBench] Starting {args.name} Benchmark\n")

mem_bytes = args.mem * 1024 * 1024 if args.mem else None

if args.out:
io_read_benchmark_user_input_data_size(other, memory_limit=args.mem)
io_read_benchmark_user_input_data_size(other, memory_limit=mem_bytes)

if args.gpu_work:
print("[WfBench] Starting GPU Benchmark...")
Expand Down Expand Up @@ -234,7 +236,7 @@ def main():

if args.out:
outputs = json.loads(args.out.replace("'", '"'))
io_write_benchmark_user_input_data_size(outputs, memory_limit=args.mem)
io_write_benchmark_user_input_data_size(outputs, memory_limit=mem_bytes)

if core:
unlock_core(path_locked, path_cores, core)
Expand Down

0 comments on commit 43ca19d

Please sign in to comment.