arpcard / rgi

Resistance Gene Identifier (RGI). Software to predict resistomes from protein or nucleotide data, including metagenomics data, based on homology and SNP models.
Other
314 stars 75 forks source link

[Help want] name 'NCBIXML' is not defined #245

Closed ZhengJinfang1220 closed 10 months ago

ZhengJinfang1220 commented 10 months ago

Dear rgi developer,

When I try to run rgi on my PC using the following command line, rgi main --input_sequence 10_prokka/10.faa --output_file rgi_out --input_type protein --alignment_tool DIAMOND --num_threads 8 --clean --include_loose But I got a warning message, WARNING 2023-09-12 05:29:46,198 : Exception: <class 'NameError'> -> name 'NCBIXML' is not defined -> model_type: variant and then no results in the output files, I have tried different biopython 1.78,1.79 and 1.81. They all not work. Can you help me to solve this problem? Thanks a lot, Jinfang Zheng

raphenya commented 10 months ago

@ZhengJinfang1220, how did you install RGI?

ZhengJinfang1220 commented 10 months ago

@raphenya

@ZhengJinfang1220, how did you install RGI?

I tried to install rgi by conda, but it took a long time to solve the environment. So, I installed the dependencies one by one. And here is some outputs of running ./test.sh

test_1.py::test_rgi_protein_sequence FAILED [ 6%] test_1.py::test_rgi_nucleotide_sequence FAILED [ 12%] test_1.py::test_rgi_homolog_model FAILED [ 18%] test_1.py::test_rgi_variant_model FAILED [ 25%] test_1.py::test_rgi_overexpression_model FAILED [ 31%] test_1.py::test_rgi_effluxpump_model FAILED [ 37%] test_1.py::test_rgi_rrna_model PASSED [ 43%] test_1.py::test_rgi_nudge_loose_to_strict FAILED [ 50%] test_3.py::test_create_local_db PASSED [ 56%] test_4.py::test_rgi_bwt PASSED [ 62%] test_5.py::test_rgi_bwt_bwa PASSED [ 68%] test_5.py::test_rgi_bwt_bwa_single PASSED [ 75%] test_5.py::test_rgi_bwt_bowtie2 PASSED [ 81%] test_5.py::test_rgi_bwt_bowtie2_single PASSED [ 87%] test_5.py::test_rgi_bwt_kma PASSED [ 93%] test_5.py::test_rgi_bwt_kma_interleaved PASSED [100%]

raphenya commented 10 months ago

@ZhengJinfang1220 Try using mamba the command will be like so to install the latest version:

mamba create --name rgi603 --channel conda-forge --channel bioconda --channel defaults rgi=6.0.3
ZhengJinfang1220 commented 10 months ago

@ZhengJinfang1220 Try using mamba the command will be like so to install the latest version:

mamba create --name rgi603 --channel conda-forge --channel bioconda --channel defaults rgi=6.0.3

Thanks, it works well.