denglab / SeqSero2

SeqSero2
Other
33 stars 18 forks source link

Biopython and its version not listed in dependencies #16

Closed kapsakcj closed 4 years ago

kapsakcj commented 5 years ago

Seems like biopython is a dependency for SeqSero2, however it is not listed in the list of dependencies in the README.

Also the latest release of biopython 1.74 (July 16, 2019) does not work with SeqSero2, particularly in allele mode. I rolled back to biopython 1.68 and it worked. I didn't test the versions in between, though it will likely work up through 1.73 since this issue occurred recently. See below

$ pip3 install 'biopython == 1.68'
Collecting biopython==1.68
  Downloading https://files.pythonhosted.org/packages/72/6c/e1e13b9df73f9c2539b67d12bc22be6b19779230cadbed04c24f3f3e5ef4/biopython-1.68.tar.gz (14.4MB)
    100% |################################| 14.4MB 85kB/s
Building wheels for collected packages: biopython
  Running setup.py bdist_wheel for biopython ... done
  Stored in directory: /root/.cache/pip/wheels/7a/c8/ed/fc0668ec5b5037afd61e05f82a3866376365c78ebf55aed195
Successfully built biopython
Installing collected packages: biopython
Successfully installed biopython-1.68

$ SeqSero2_package.py -m a -p 16 -t 2 -i SRR1258439_1.fastq.gz SRR1258439_2.fastq.gz
building database...
mapping...
check samtools version: 1.9
[bam_sort_core] merging from 0 files and 16 in-memory blocks...
assembling...
blasting...

Output_directory:SeqSero_result_08_30_2019_14_22_411813448
Input files:    SRR1258439_1.fastq.gz SRR1258439_2.fastq.gz
O antigen prediction:   7
H1 antigen prediction(fliC):    y
H2 antigen prediction(fljB):    1,5
Predicted subspecies:   I
Predicted antigenic profile:    7:y:1,5
Predicted serotype:     Bareilly

$ pip3 install --upgrade biopython
Collecting biopython
  Using cached https://files.pythonhosted.org/packages/36/3a/35d78250cb04ced183db3c01344737a7cf95a163f3267383a21e86784a3d/biopython-1.74-cp35-cp35m-manylinux1_x86_64.whl
Collecting numpy (from biopython)
  Downloading https://files.pythonhosted.org/packages/d4/64/7619774f0bd8ef364d46a5df8eb1bc78784cd787324b9624f6793e72f787/numpy-1.17.1-cp35-cp35m-manylinux1_x86_64.whl (20.1MB)
    100% |################################| 20.2MB 62kB/s
Installing collected packages: numpy, biopython
  Found existing installation: numpy 1.17.0
    Uninstalling numpy-1.17.0:
      Successfully uninstalled numpy-1.17.0
  Found existing installation: biopython 1.68
    Uninstalling biopython-1.68:
      Successfully uninstalled biopython-1.68
Successfully installed biopython-1.74 numpy-1.17.1

$ SeqSero2_package.py -m a -p 16 -t 2 -i SRR1258439_1.fastq.gz SRR1258439_2.fastq.gz
building database...
mapping...
check samtools version: 1.9
[bam_sort_core] merging from 0 files and 16 in-memory blocks...
assembling...
blasting...

Traceback (most recent call last):
  File "/SeqSero2-1.0.0/SeqSero2_package.py", line 1423, in <module>
    main()
  File "/SeqSero2-1.0.0/SeqSero2_package.py", line 1264, in main
    Final_list=xml_parse_score_comparision_seqsero(xmlfile) #analyze xml and get parsed results
  File "/SeqSero2-1.0.0/SeqSero2_package.py", line 509, in xml_parse_score_comparision_seqsero
    score+=hsp.bits*fraction
TypeError: unsupported operand type(s) for *: 'NoneType' and 'int'
LSTUGA commented 5 years ago

Thanks for catching that. We've added biopython and the version (1.73) we used into the dependencies. We will do some troubleshooting using biopython 1.74 and try to fix this problem.

kapsakcj commented 4 years ago

Thanks for adding this to the README. Really helps those of us that install seqsero2 from source! Closing this issue