Git Product home page Git Product logo

quadram-institute-bioscience / socru Goto Github PK

View Code? Open in Web Editor NEW
25.0 4.0 6.0 230.92 MB

Order and orientation of complete bacterial genomes

Home Page: https://doi.org/10.1099/mgen.0.000396

License: GNU General Public License v3.0

Python 99.70% Shell 0.05% Dockerfile 0.25%
bioinformatics python3 bacteria long-reads assembly complete bioinformatics-pipeline infectious-diseases genomics

socru's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

socru's Issues

pip3 instead of pip

pip install git+https://github.com/quadram-institute-bioscience/socru

# to minimize your future pain

pip3 ....

PyYAML 5.1 deprecates yaml.load without setting loader

running socru-2.2.2 with PyYAML 5.1 generate a warning

see:

c6builder:socru/2.2.2 > socru Escherichia_coli ../../datas/socru/ecoli.fa
/local/gensoft2/exe/socru/2.2.2/lib/python3.6/site-packages/socru/Profiles.py:39: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
  metadata = yaml.load(metadatafh)
../../datas/socru/ecoli.fa      GREEN   GS1.0   1       2       3       4      56       7

easy fix is to change yaml.load(call) in Profiles.py
from

metadata = yaml.load(metadatafh)

to

metadata = yaml.load(metadatafh, yaml.SafeLoader)

regards

Eric

socru_species error (missing required positional argument: verbose)

Getting this error when running socru_species:

Schemas().print_all()
TypeError: __init__() missing 1 required positional argument: 'verbose'

I installed socru using conda, and socru by itself seems to work fine (or print out the help message at least). I checked that I have python 3.7 installed.

Expected output?

I ran Socru version 2.2.4 and got the file described as 'Pimary output' in the documentation. The pirmary output contained the expected number of lines compared to the number of genomes given as input. However, I did not get any other output files.

The command I ran was:
socru Streptococcus_pyogenes File/Path/to/*.fna -t 16 --output_file File/Path/to/Refseq_Socru_140520 -v

I looked in the verbose output for clues to the missing output files but could not identify any.
I would expect to get other outputs like the operon_directions.txt, but why are they not given?
Thank you in advance!

Invalid Campylobacter jejuni assemblies

Describe the bug
I have a problem running Socru on Campylobacter jejuni assemblies. The Campylobacter genome can be separated into three fragments separated by ribosomal operons. For Campylobacter coli, the origin of replication (Ori) is in fragment 3 and the terminus (ter) is in fragment 1, and Socru can easily be used to identify misassembles for this species. However, for Campylobacter jejuni Ori and Ter are both on fragment 1. Because of this, Socru always calls the assemblies invalid.

Campylobacter jejuni RED GS1.0 1 2 3 Invalid --> 1(Ori)(Ter) --> 2 --> 3
Campylobacter coli GREEN GS1.0 1 2 3 Valid --> 1(Ter) <-- 2 <-- 3(Ori)

In addition, the operon direction file always shows Ori and Ter in alphabetical order on fragment 1, making it difficult to determine if the assembly is valid using Socru. To test this I took a C. jejuni chromosome, determined its reverse compliment and placed it through Socru, and Ori was still before Ter on fragment 1.

Normal Campylobacter jejuni RED GS1.0 1 2 3 Invalid --> 1(Ori)(Ter) --> 2 --> 3
Reverse compliment Campylobacter jejuni RED GS1.0 1 2 3 Invalid <-- 1(Ori)(Ter) <-- 3 <-- 2

Therefore, if Ori and Ter are on the same fragment can Socru be changed to give the order of Ori and Ter as they appear on the fragment, and can it call C. jejuni assemblies with Ori and Ter on fragment 1 valid.

Conda install not working

Have been using Socru previously but had to reinstall and when using the conda installation I got the following error:

Traceback (most recent call last):
  File "/home/georgia/miniconda3/envs/python3.6/bin/socru", line 10, in <module>
    from socru.Socru import Socru
ModuleNotFoundError: No module named 'socru' 

The pip installation worked fine so I'm happily using this but just wanted to alert to the fact that the Conda installation had issues.

For reference the conda install was into a clean environment on a linux machine.

Bio.alphabet error

Describe the bug

Hi, I installed socru using Conda v 2.2.4 and got this error when I tried it on an isolate

Traceback (most recent call last):
File "/Users/a1667917/mambaforge/envs/socru/bin/socru", line 10, in
from socru.Socru import Socru
File "/Users/a1667917/mambaforge/envs/socru/lib/python3.9/site-packages/socru/Socru.py", line 13, in
from socru.FragmentFiles import FragmentFiles
File "/Users/a1667917/mambaforge/envs/socru/lib/python3.9/site-packages/socru/FragmentFiles.py", line 4, in
from Bio.Alphabet import generic_dna
File "/Users/a1667917/mambaforge/envs/socru/lib/python3.9/site-packages/Bio/Alphabet/init.py", line 20, in
raise ImportError(
ImportError: Bio.Alphabet has been removed from Biopython. In many cases, the alphabet can simply be ignored and removed from scripts. In a few cases, you may need to specify the molecule_type as an annotation on a SeqRecord for your script to work correctly. Please see https://biopython.org/wiki/Alphabet for more information.

Additional context
This error was fixed when I commented out socru/FragmentFiles.py line 4 and socru ran fine without any issues.

George

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.