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

Sample.fasta.temp.draft file not found #242

Closed jenniferlu717 closed 1 day ago

jenniferlu717 commented 11 months ago

Hello,

I am trying to run rgi on a set of metagenomic samples. The command I run is

rgi main --input_sequence SAMPLE.fasta --output_file testing --local --clean --low-quality

However, anytime I run this command, I end up with this error:

File "/usr/local/lib/python3.10/dist-packages/app/ORF.py", line 28, in contig_to_orf self.orf_prodigal() File "/usr/local/lib/python3.10/dist-packages/app/ORF.py", line 73, in orf_prodigal os.remove(os.path.join(self.working_directory, "{}.temp.draft".format(filename))) FileNotFoundError: [Errno 2] No such file or directory: 'SAMPLE.fasta.temp.draft'

raphenya commented 11 months ago

@jenniferlu717 This looks like prodigal is not installed. Also, the option --low-quality should be --low_quality. I tested with rgi 5.2.1 and 6.0.1. I will need more information to thoroughly test this, e.g., which version of rgi and what type of sequence is in SAMPLE.fasta.

github-actions[bot] commented 8 months ago

Issue is stale and will be closed in 7 days unless there is new activity

rvincenzi commented 4 months ago

I have the same problem. How can I check if it is everything ok with prodigal? @raphenya

I'm running this command:

rgi main -n 8 --input_sequence /Users/rvincenzi/Documents/USP/nepalensis_report/nepalensis_dataset/fasta/ColB_scaffolds.fasta --output_file /Users/rvincenzi/Documens/USP/nepalensis_report/RGIoutput_file --local --clean

And I get the following error message:

Traceback (most recent call last):

File "/Users/rvincenzi/miniforge3/envs/rgi/bin/rgi", line 4, in MainBase() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/MainBase.py", line 83, in init getattr(self, args.command)() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/MainBase.py", line 88, in main self.main_run(args) File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/MainBase.py", line 128, in main_run rgi_obj.run() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/RGI.py", line 254, in run self.run_blast() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/RGI.py", line 318, in run_blast self.process_contig() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/RGI.py", line 352, in process_contig orf_obj.contig_to_orf() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/ORF.py", line 28, in contig_to_orf self.orf_prodigal() File "/Users/rvincenzi/miniforge3/envs/rgi/lib/python3.8/site-packages/app/ORF.py", line 73, in orf_prodigal os.remove(os.path.join(self.working_directory, "{}.temp.draft".format(filename))) FileNotFoundError: [Errno 2] No such file or directory: '/Users/rvincenzi/Documens/USP/nepalensis_report/ColB_scaffolds.fasta.temp.draft'

RGI version: 6.0.3 Prodigal version: v2.6.3

gezmi commented 3 months ago

I encountered the same issue, with an installation that was working for years perfectly, so I am absolutely clueless on what could have happened...

The above error comes when I use --clean. If I do not, it changes to the error below:

 rgi main -d plasmid -t contig --local -a blast  --input_sequence /home/incfinder/incfinder/storage/app/public/db/fasta/CP131692.fasta --output_file CP131692 --debug
INFO 2024-04-28 00:35:35,941 : /home/incfinder/incfinder/storage/app/public/db/fasta/CP131692.fasta => None
INFO 2024-04-28 00:35:36,096 : valid nucleotide fasta: {'A': 45670, 'T': 42376, 'G': 50029, 'C': 46161, 'N': 0, 'U': 0, 'W': 0, 'S': 0, 'M': 0, 'K': 0, 'R': 0, 'Y': 0, 'B': 0, 'D': 0, 'H': 0, 'V': 0}
INFO 2024-04-28 00:35:36,096 : blast DB exists
INFO 2024-04-28 00:35:36,096 : diamond DB exists
INFO 2024-04-28 00:35:36,099 : minimum sequence length: 184236, maximun sequence length 184236, number of sequences: 1
ERROR 2024-04-28 00:35:36,109 : failed to write orf file
Traceback (most recent call last):
  File "/home/incfinder/anaconda3/envs/rgi/lib/python3.6/site-packages/app/RGI.py", line 286, in process_contig
    if os.stat(contig_fsa_file).st_size > 0:
FileNotFoundError: [Errno 2] No such file or directory: '/home/incfinder/incfinder/CP131692.fasta.temp.contig.fsa'
INFO 2024-04-28 00:35:36,110 : run filter
ERROR 2024-04-28 00:35:36,110 : missing blast xml file(). Please check if input_type: 'contig' correspond with input file: '/home/incfinder/incfinder/storage/app/public/db/fasta/CP131692.fasta' or use '--low_quality' flag for short contigs to predicts partial genes.
INFO 2024-04-28 00:35:36,110 : Total running time 0.169s
agmcarthur commented 2 months ago

New report @raphenya

github-actions[bot] commented 1 week ago

Issue is stale and will be closed in 7 days unless there is new activity