Skip to content

Commit 3212069

Browse files
committed
[query] Benchmark configurations
1 parent 199105c commit 3212069

File tree

8 files changed

+229
-134
lines changed

8 files changed

+229
-134
lines changed

hail/python/benchmark/hail/benchmark_benchmark_analysis.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
from benchmark.tools.statistics import analyze_benchmarks
88

99

10-
@pytest.mark.benchmark()
10+
@pytest.mark.benchmark(mds=1.2, instances=10, iterations=5, burn_in_iterations=10)
1111
def benchmark_analyze_benchmarks(local_tmpdir, onethreetwo, onethreethree):
1212
inputs = (onethreetwo, onethreethree)
1313
inputs = ((v, Path(tempfile.mktemp(dir=local_tmpdir))) for v in inputs)

hail/python/benchmark/hail/benchmark_combiner.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,30 +24,30 @@ def benchmark_compile_2k_merge(empty_gvcf, tmp_path):
2424
hl.vds.write_variant_datasets(combined, str(tmp_path / 'combiner-multi-write'), overwrite=True)
2525

2626

27-
@pytest.mark.benchmark()
27+
@pytest.mark.benchmark(mds=1.1, instances=10, iterations=10, burn_in_iterations=10)
2828
@pytest.mark.xtimeout(270)
2929
def benchmark_python_only_10k_transform(empty_gvcf):
3030
for vcf in [import_vcf(empty_gvcf)] * 10_000:
3131
transform_gvcf(vcf, [])
3232

3333

34-
@pytest.mark.benchmark()
34+
@pytest.mark.benchmark(mds=1.1, instances=10, iterations=10, burn_in_iterations=20)
3535
def benchmark_python_only_10k_combine(empty_gvcf):
3636
vcf = import_vcf(empty_gvcf)
3737
mt = transform_gvcf(vcf, [])
3838
for mts in chunk(COMBINE_GVCF_MAX, [mt] * 10_000):
3939
combine_variant_datasets(mts)
4040

4141

42-
@pytest.mark.benchmark()
42+
@pytest.mark.benchmark(mds=1.1, instances=20, iterations=10, burn_in_iterations=10)
4343
def benchmark_import_and_transform_gvcf(single_gvcf):
4444
mt = import_vcf(single_gvcf)
4545
vds = transform_gvcf(mt, [])
4646
vds.reference_data._force_count_rows()
4747
vds.variant_data._force_count_rows()
4848

4949

50-
@pytest.mark.benchmark()
50+
@pytest.mark.benchmark(mds=1.2, instances=10, iterations=15, burn_in_iterations=8)
5151
def benchmark_import_gvcf_force_count(single_gvcf):
5252
mt = import_vcf(single_gvcf)
5353
mt._force_count_rows()
@@ -62,7 +62,7 @@ def tmp_and_output_paths(tmp_path):
6262
return (tmp, output)
6363

6464

65-
@pytest.mark.benchmark()
65+
@pytest.mark.benchmark(mds=1.1, instances=10, iterations=5, burn_in_iterations=10)
6666
@pytest.mark.xtimeout(180)
6767
def benchmark_vds_combiner_chr22(chr22_gvcfs, tmp_and_output_paths):
6868
parts = hl.eval([hl.parse_locus_interval('chr22:start-end', reference_genome='GRCh38')])

hail/python/benchmark/hail/benchmark_linalg.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,32 +12,32 @@ def benchmark_block_matrix_nested_multiply(tmp_path):
1212
bm.write(str(tmp_path / 'result.mt'), overwrite=True)
1313

1414

15-
@pytest.mark.benchmark()
15+
@pytest.mark.benchmark(mds=1.2, instances=10, iterations=5, burn_in_iterations=5)
1616
def benchmark_make_ndarray():
1717
ht = hl.utils.range_table(200_000)
1818
ht = ht.annotate(x=hl.nd.array(hl.range(ht.idx)))
1919
ht._force_count()
2020

2121

22-
@pytest.mark.benchmark()
22+
@pytest.mark.benchmark(mds=1.2, instances=10, iterations=20, burn_in_iterations=10)
2323
def benchmark_ndarray_addition():
2424
arr = hl.nd.ones((1024, 1024))
2525
hl.eval(arr + arr)
2626

2727

28-
@pytest.mark.benchmark()
28+
@pytest.mark.benchmark(mds=1.2, instances=20, iterations=5, burn_in_iterations=10)
2929
def benchmark_ndarray_matmul_int64():
3030
arr = hl.nd.arange(1024 * 1024).map(hl.int64).reshape((1024, 1024))
3131
hl.eval(arr @ arr)
3232

3333

34-
@pytest.mark.benchmark()
34+
@pytest.mark.benchmark(mds=1.1, instances=20, iterations=15, burn_in_iterations=6)
3535
def benchmark_ndarray_matmul_float64():
3636
arr = hl.nd.arange(1024 * 1024).map(hl.float64).reshape((1024, 1024))
3737
hl.eval(arr @ arr)
3838

3939

40-
@pytest.mark.benchmark()
40+
@pytest.mark.benchmark(mds=1.2, instances=10, iterations=5, burn_in_iterations=10)
4141
@pytest.mark.xtimeout(200)
4242
def benchmark_blockmatrix_write_from_entry_expr_range_mt(tmp_path):
4343
mt = hl.utils.range_matrix_table(40_000, 40_000, n_partitions=4)
@@ -55,13 +55,14 @@ def benchmark_blockmatrix_write_from_entry_expr_range_mt_standardize(tmp_path):
5555
)
5656

5757

58-
@pytest.mark.benchmark()
58+
@pytest.mark.benchmark(mds=1.1, instances=5, iterations=8, burn_in_iterations=10)
59+
@pytest.mark.xtimeout(200)
5960
def benchmark_sum_table_of_ndarrays():
6061
ht = hl.utils.range_table(400).annotate(nd=hl.nd.ones((4096, 4096)))
6162
ht.aggregate(hl.agg.ndarray_sum(ht.nd))
6263

6364

64-
@pytest.mark.benchmark()
65+
@pytest.mark.benchmark(mds=1.1, instances=10, iterations=5, burn_in_iterations=4)
6566
@pytest.mark.xtimeout(250)
6667
def benchmark_block_matrix_to_matrix_table_row_major():
6768
mt = hl.utils.range_matrix_table(20_000, 20_000, n_partitions=4)

0 commit comments

Comments
 (0)