pandora icon indicating copy to clipboard operation
pandora copied to clipboard

Slow KmerGraph test

Open mbhall88 opened this issue 6 years ago • 5 comments

This test takes ~5.5 seconds to execute. Is there a way we could shorten it and still test the same functionality? https://github.com/rmcolq/pandora/blob/a1d02878fa85b49ee59445ebc220a45ecd54eb7f/test/kmergraph_test.cpp#L367-L378

mbhall88 avatar Apr 01 '19 10:04 mbhall88

It takes ages because it's based on real cases where there were bugs at some point. At the time I didn't know what the bugs were. The shorter one would probably be good enough.

rmcolq avatar Apr 01 '19 10:04 rmcolq

So if you know what the bugs are now is it possible to make shorter examples that pinpoint them? Or is the length something that triggers the bug?

mbhall88 avatar Apr 01 '19 11:04 mbhall88

From memory it was mostly bugs elsewhere not caught by other tests at the time. The length was not important but problem was with pruning edges which are surplus (arise due to local way we find the next kmer) which resulted in non connectedness when the wrong edges were pruned. A better test would test cleaning of kmer graph instead.

Sent from my Samsung Galaxy smartphone.

-------- Original message -------- From: Michael Hall [email protected] Date: 01/04/2019 07:56 (GMT-05:00) To: rmcolq/pandora [email protected] Cc: Rachel Norris [email protected], Comment [email protected] Subject: Re: [rmcolq/pandora] Slow KmerGraph test (#118)

So if you know what the bugs are now is it possible to make shorter examples that pinpoint them? Or is the length something that triggers the bug?

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://github.com/rmcolq/pandora/issues/118#issuecomment-478549391, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AJaLO-m0iD9mGIysNwcry51_e5BSDKD3ks5vcfQCgaJpZM4cVZzB.

rmcolq avatar Apr 01 '19 17:04 rmcolq

Sorry to be obtuse, but is 5s really a problem? Does it run in a loop or some?

iqbal-lab avatar May 17 '19 08:05 iqbal-lab

5s is in the best case. Sometimes over 10s. Personally, I feel like a single unittest shouldn't take this long. If no one else agrees though, obviously the majority rules.

Not saying this is necessarily a high priority issue - but can be a pain when debugging and running the test suite a lot.

mbhall88 avatar May 17 '19 08:05 mbhall88