Skip to content
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

Created a debug output mode that dumps the the exact inputs/outputs of the PairHMM to a file #7660

Merged
merged 6 commits into from
Mar 10, 2022

Conversation

jamesemery
Copy link
Collaborator

Resolves #7647

@jamesemery
Copy link
Collaborator Author

@droazen could you take a look at this branch?

Copy link
Collaborator

@droazen droazen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jamesemery Back to you with a couple of quick comments. Main question is why the AVX_LOGLESS_CACHING test case is disabled

if(doProfiling)
logger.info("Total compute time in PairHMM computeLogLikelihoods() : "+(pairHMMComputeTime*1e-9));
if(doProfiling) {
logger.info("Total compute time in PairHMM computeLogLikelihoods() : " + (pairHMMComputeTime * 1e-9));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the time unit here? Seconds?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seconds I believe just as it has in the past for gatk. Its using nanoTime so converting to seconds should be 10^-9.

*/
@Advanced
@Hidden
@Argument(fullName="pair-hmm-results-file", doc="File to write exact pairHMM inputs/outputs to for debugging purposes", optional = true)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do all of the available HMMs respect this argument, or only some of them? If only some, list the ones that respect it.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all of them as far as i've tested. I have a test for all of them but the AVX was producing some different output on travis...


if (debugOutputStream!= null) {
try {
debugOutputStream.write("\n" + new String(alleleBases) + " " + new String(readBases) + " " + SAMUtils.phredToFastq(readQuals) + " " + SAMUtils.phredToFastq(readInsQuals) + " " + SAMUtils.phredToFastq(readDelQuals) + " " + SAMUtils.phredToFastq(overallGCP) + " " + String.format("%e",lk));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirming that the values in this table will never contain internal whitespace?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so. If the alleles or the phred to fastq mehtods are returning results with whitespaces in them we have much bigger problems...

@DataProvider(name="PairHMMResultsModes")
public Object[][] PairHMMResultsModes() {
return new Object[][] {
//{PairHMM.Implementation.AVX_LOGLESS_CACHING, new File(TEST_FILES_DIR, "expected.AVX.hmmresults.txt")}, //TODO disabled because of failures on travis
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you elaborate on why this is disabled? Ideally we want test coverage for the default HMM in GATK...

@jamesemery jamesemery force-pushed the je_PairHMMDebugOutputForTesting branch from 2c14923 to dc06537 Compare March 9, 2022 21:41
@jamesemery
Copy link
Collaborator Author

@droazen I loosened the failing test and responded to your comments? Anything else before we can get this in?

Copy link
Collaborator

@droazen droazen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@droazen droazen merged commit 241d13a into master Mar 10, 2022
@droazen droazen deleted the je_PairHMMDebugOutputForTesting branch March 10, 2022 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add option to dump PairHMM debugging outputs to a file in a standard format
2 participants