Skip to content

Commit

Permalink
ALS-5819: Add logging to determine patients per variant
Browse files Browse the repository at this point in the history
  • Loading branch information
ramari16 committed Feb 6, 2024
1 parent 7c4b007 commit ecc1546
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,9 @@ public BigInteger getPatientIdsForIntersectionOfVariantSets(Set<Integer> patient
BigInteger heteroMask = masks.heterozygousMask == null ? variantService.emptyBitmask() : masks.heterozygousMask;
BigInteger homoMask = masks.homozygousMask == null ? variantService.emptyBitmask() : masks.homozygousMask;
BigInteger orMasks = heteroMask.or(homoMask);
BigInteger andMasks = orMasks.and(patientsInScopeMask);
log.info("Patients with variant " + variantSpec + ": " + (orMasks.bitCount()));
synchronized(matchingPatients) {
matchingPatients[0] = matchingPatients[0].or(andMasks);
matchingPatients[0] = matchingPatients[0].or(orMasks);
}
}, () -> missingVariants.add(variantSpec));
});
Expand All @@ -90,7 +90,7 @@ public BigInteger getPatientIdsForIntersectionOfVariantSets(Set<Integer> patient
}
});
}
return matchingPatients[0];
return matchingPatients[0].and(patientsInScopeMask);
}else {
log.error("No matches found for info filters.");
return createMaskForPatientSet(new HashSet<>());
Expand Down

0 comments on commit ecc1546

Please sign in to comment.