Skip to content

Commit 2e8189b

Browse files
egedemircid1vyanshu
andcommitted
Update run_experiments.py
Co-Authored-By: Divyanshu Bhardwaj <[email protected]>
1 parent 3408948 commit 2e8189b

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

.DS_Store

0 Bytes
Binary file not shown.

run_experiments.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,11 @@
1010
"benchmarks/fib_benchmark.py",
1111
"benchmarks/sort_benchmark.py",
1212
"benchmarks/io_benchmark.py",
13-
"benchmarks/memory_benchmark.py",
14-
"benchmarks/concurrency_benchmark.py",
1513
"benchmarks/json_benchmark.py",
1614
"benchmarks/nbody_benchmark.py",
1715
"benchmarks/asyncio_benchmark.py",
18-
"benchmarks/dictionary_benchmark.py"
16+
"benchmarks/dictionary_benchmark.py",
17+
"benchmarks/prime.py"
1918
]
2019

2120
interpreters = {"CPython": "python3", "PyPy": "pypy3", "Jython": "jython"}
@@ -49,7 +48,6 @@ def run_benchmark(interpreter, script):
4948
mem_before = rusage_before.ru_maxrss
5049
mem_after = rusage_after.ru_maxrss
5150
peak = max(mem_before, mem_after)
52-
data["peak_memory_MB"] = peak / 1024.0
5351
data["interpreter"] = interpreter
5452
data["script"] = script
5553
if "timestamp" not in data:
@@ -72,7 +70,7 @@ def main():
7270
with open(results_csv, "w", newline="") as csvfile:
7371
fieldnames = [
7472
"timestamp", "interpreter", "script", "benchmark",
75-
"iterations", "runtime", "wall_time", "cpu_time", "peak_memory_MB"
73+
"iterations", "runtime", "wall_time", "cpu_time"
7674
]
7775
writer = csv.DictWriter(csvfile, fieldnames=fieldnames)
7876
writer.writeheader()
@@ -86,8 +84,7 @@ def main():
8684
"iterations": r.get("iterations"),
8785
"runtime": r.get("runtime"),
8886
"wall_time": r.get("wall_time"),
89-
"cpu_time": r.get("cpu_time"),
90-
"peak_memory_MB": r.get("peak_memory_MB")
87+
"cpu_time": r.get("cpu_time")
9188
})
9289
print(f"All results have been saved to {results_csv}")
9390
else:

0 commit comments

Comments
 (0)