Skip to content

fix additional location #824

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions v03_pipeline/lib/misc/lookup.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,12 @@ def remove_family_guids(
if project_guid not in hl.eval(ht.globals.project_families):
return ht
project_i = ht.project_guids.index(project_guid)
family_indexes_to_keep = hl.array(
hl.enumerate(ht.globals.project_families[project_guid])
.filter(lambda item: ~family_guids.contains(item[1]))
.map(lambda item: item[0]),
family_indexes_to_keep = hl.eval(
hl.array(
hl.enumerate(ht.globals.project_families[project_guid])
.filter(lambda item: ~family_guids.contains(item[1]))
.map(lambda item: item[0]),
),
)
ht = ht.annotate(
project_stats=(
Expand All @@ -90,8 +92,12 @@ def remove_family_guids(
hl.if_else(
i != project_i,
fs,
family_indexes_to_keep.map(
lambda j: ht.project_stats[i][j],
(
hl.array(family_indexes_to_keep).map(
lambda j: ht.project_stats[i][j],
)
if len(family_indexes_to_keep) > 0
else hl.empty_array(ht.project_stats[i].dtype.element_type)
),
)
),
Expand Down
Loading