Ecogenomics / BamM

Metagenomics-focused BAM file manipulation
http://ecogenomics.github.io/BamM/
GNU Lesser General Public License v3.0
16 stars 7 forks source link

nosetests fails #18

Closed nr0cinu closed 9 years ago

nr0cinu commented 9 years ago

Hi!

I want to try GroopM, and thereby need BamM.

I followed the manual to the letter (system-wide install), and I get these 2 errors when running nosetests. I would appreciate some help!

I’m running up-to-date Ubuntu 14.10.

Thanks! Bela

~/repos/_software/BamM$ nosetests
.FF..........................................
======================================================================
FAIL: test_bamParser.TestBamParser.test_B_parse
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/local/bela/repos/_software/BamM/bamm/tests/test_bamParser.py", line 184, in test_B_parse
    assert_equals(po[i], res[i])
AssertionError: 0.042700000000000002 != 0.032000000000000001

======================================================================
FAIL: test_bamParser.TestBamParser.test_C_extract
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/local/bela/repos/_software/BamM/bamm/tests/test_bamParser.py", line 241, in test_C_extract
    assert_equals(len(headers), len(test_headers))
AssertionError: 2 != 4

----------------------------------------------------------------------
Ran 45 tests in 0.831s

FAILED (failures=2)
minillinim commented 9 years ago

Hi,

Sorry to hear you're having problems. Could you please run the following code and let me know the output. Also, which version of BamM are you running?

Thanks.

wwood commented 9 years ago

Forgot to add the code to run MIke?

minillinim commented 9 years ago

Umm. it's not attached?

Definitely attaching it this time.

wwood commented 9 years ago

Definitely not. https://github.com/minillinim/BamM/issues/18#issuecomment-73869968

On 12 February 2015 at 16:42, Michael Imelfort notifications@github.com wrote:

Umm. it's not attached?

Definitely attaching it this time.

— Reply to this email directly or view it on GitHub https://github.com/minillinim/BamM/issues/18#issuecomment-74025048.

Ben Woodcroft http://ecogenomic.org/users/ben-woodcroft http://www.ecogenomic.org/

minillinim commented 9 years ago

Oops,

can't add attachments to github messages.

I added the code to the "test" folder in BamM.

$ git pull

to get hold of it.

Sorry...

nr0cinu commented 9 years ago

Hi,

I’m using the most currect version directly from GitHub.

$ ./sysInfoBamM.py 
Numpy version: 1.8.2
Location: /usr/lib/python2.7/dist-packages/numpy/__init__.pyc
Linux 3.16.0-30-generic
2.7.8 (default, Oct 20 2014, 15:05:19) 
[GCC 4.9.1]
['/local/bela/repos/_software/BamM/bamm/tests', '/usr/local/lib/python2.7/dist-packages/ete2-2.2.1072-py2.7.egg', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages/PILcompat', '/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/pymodules/python2.7', '/usr/lib/python2.7/dist-packages/ubuntu-sso-client']

python test_bamParser.py does give any output

Thanks, Bela

minillinim commented 9 years ago

Hi, thanks for that. What version of bwa do you have installed?

nr0cinu commented 9 years ago

0.7.9a-r786

minillinim commented 9 years ago

I think this may be your problem. I noticed when I was running bwa 0.7.10 that it gave different mappings to previous versions. The nosetests simulate mapping and coverage calculations and then expect bwa to give the same result. Updating to the latest bwa gave mappings which were consistent with the model used to generate the test data. Are you able to upgrade your bwa?

see here for details: https://github.com/lh3/bwa/blob/master/NEWS.md

Hope this helps. If this is the problem then you should be good to use BamM/GroopM even without updating bwa. Generally, for reasonably covered contigs, the coverage profile is quite robust, so a few missed reads from bwa shouldn't mess stuff up... ...I think

nr0cinu commented 9 years ago

I pushed bwa to 0.7.10-r789, but I still get the same erros. Or do I need to recompile something after updating bwa?

minillinim commented 9 years ago

0.7.10 has the bug too.

0.7.12 is the fixed version.