Skip to content

Commit

Permalink
[query] Add a new benchmark testing speed of collect (#10972)
Browse files Browse the repository at this point in the history
* Add a new benchmark testing speed of collect

* Rename and increase size
  • Loading branch information
johnc1231 authored Oct 14, 2021
1 parent 1613273 commit d427851
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -371,3 +371,10 @@ def matrix_multi_write_nothing():
mt = hl.utils.range_matrix_table(1, 1, n_partitions=1)
mts = [mt] * 1000
hl.experimental.write_matrix_tables(mts, path.join(tmpdir, 'multi-write'), overwrite=True)


@benchmark(args=profile_25.handle("mt"))
def mt_localize_and_collect(mt_path):
mt = hl.read_matrix_table(mt_path)
ht = mt.localize_entries("ent")
collected = ht.head(150).collect()

0 comments on commit d427851

Please sign in to comment.