-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathtest.py
More file actions
21 lines (16 loc) · 767 Bytes
/
test.py
File metadata and controls
21 lines (16 loc) · 767 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import cupy_prof
def run_bench(bench_class):
bench = benchmark()
cupy_prof.Measure(bench).measure()
if __name__ == '__main__':
benchmarks = [cupy_prof.benchmarks.core.CreationBenchmark,
cupy_prof.benchmarks.core.CreationBenchmarkSquares,
cupy_prof.benchmarks.core.StackingBenchmark,
cupy_prof.benchmarks.core.ArrayBenchmark,
cupy_prof.benchmarks.core.FromArrayBenchmark,
cupy_prof.benchmarks.core.TemporariesBenchmark,
cupy_prof.benchmarks.ufunc.UfuncBenchmark,
cupy_prof.benchmarks.noncontiguous.ReductionBenchmark]
for benchmark in benchmarks:
print('Running', benchmark.__name__)
run_bench(benchmark)