Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in rule classify_full_and_part_by_group: #173

Open
TiAmoTYX opened this issue Oct 17, 2023 · 6 comments
Open

Error in rule classify_full_and_part_by_group: #173

TiAmoTYX opened this issue Oct 17, 2023 · 6 comments

Comments

@TiAmoTYX
Copy link

[2023-10-17 10:10 INFO] VirSorter 2.2.4
[2023-10-17 10:10 INFO] /usr/local/bin/virsorter run -w outputs -i ./data/ComND.Sep_final_Scaftigs.fasta --min-length 1500 -j 4 all
[2023-10-17 10:10 INFO] Using /content/VirSorter2/virsorter/template-config.yaml as config template
Traceback (most recent call last):
File "/usr/local/bin/virsorter", line 33, in
sys.exit(load_entry_point('virsorter', 'console_scripts', 'virsorter')())
File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1128, in call
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1053, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1659, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1395, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.6/site-packages/click/core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "/content/VirSorter2/virsorter/virsorter.py", line 369, in run_workflow
viral_gene_enrich_off=viral_gene_enrich_off,
File "/content/VirSorter2/virsorter/config.py", line 151, in make_config
groups_avail = os.listdir(f'{db_dir}/group')
FileNotFoundError: [Errno 2] No such file or directory: '/VirSorter2/db/group'
[55]

#增加hmmscan线程数提高运行速度
!virsorter config --set HMMSEARCH_THREADS=4
[86]
4 秒
!virsorter run -w outputs -i ./data/ComND.Sep_final_Scaftigs.fasta --min-length 1500 -j 4 all --db-dir /content/VirSorter2/db

output
[2023-10-17 10:38 INFO] VirSorter 2.2.4
[2023-10-17 10:38 INFO] /usr/local/bin/virsorter run -w outputs -i ./data/ComND.Sep_final_Scaftigs.fasta --min-length 1500 -j 4 all --db-dir /content/VirSorter2/db
[2023-10-17 10:38 INFO] Using /content/VirSorter2/virsorter/template-config.yaml as config template
[2023-10-17 10:38 INFO] conig file written to /content/VirSorter2/outputs/config.yaml

[2023-10-17 10:38 INFO] Executing: snakemake --snakefile /content/VirSorter2/virsorter/Snakefile --directory /content/VirSorter2/outputs --jobs 4 --configfile /content/VirSorter2/outputs/config.yaml --latency-wait 600 --rerun-incomplete --nolock --conda-frontend mamba --conda-prefix /content/VirSorter2/db/conda_envs --use-conda --quiet all
Job stats:
job count min threads max threads


all 1 1 1
classify 1 1 1
classify_full_and_part_by_group 2 1 1
finalize 1 1 1
merge_full_and_part_classification 1 1 1
total 6 1 1

[2023-10-17 10:38 ERROR] See error details in /content/VirSorter2/outputs/log/iter-0/step3-classify/provirus-score-ssDNA.log
[Tue Oct 17 10:38:12 2023]
Error in rule classify_full_and_part_by_group:
jobid: 60
output: iter-0/ssDNA/viral.trim.clf
conda-env: /content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d
shell:

        Log=/content/VirSorter2/outputs/log/iter-0/step3-classify/provirus-score-ssDNA.log
        Hallmark_list_f=/content/VirSorter2/db/group/ssDNA/hallmark-gene.list
        if [ -s $Hallmark_list_f ]; then
            python /content/VirSorter2/virsorter/./scripts/classify-trimed.py iter-0/ssDNA/all.pdg.gff iter-0/ssDNA/all.pdg.hmm.tax /content/VirSorter2/db/rbs/rbs-catetory.tsv /content/VirSorter2/db/group/ssDNA/model iter-0/viral-combined.fa iter-0/ssDNA/viral.trim.clf --group ssDNA --hallmark /content/VirSorter2/db/group/ssDNA/hallmark-gene.list 2> $Log || { echo "See error details in $Log" | python /content/VirSorter2/virsorter/./scripts/echo.py --level error; exit 1; }
        else
            python /content/VirSorter2/virsorter/./scripts/classify-trimed.py iter-0/ssDNA/all.pdg.gff iter-0/ssDNA/all.pdg.hmm.tax /content/VirSorter2/db/rbs/rbs-catetory.tsv /content/VirSorter2/db/group/ssDNA/model iter-0/viral-combined.fa iter-0/ssDNA/viral.trim.clf --group ssDNA 2> $Log || { echo "See error details in $Log" | python /content/VirSorter2/virsorter/./scripts/echo.py --level error; exit 1; }
        fi

        
    (one of the commands exited with non-zero exit code; note that snakemake uses bash strict mode!)

[2023-10-17 10:38 ERROR] See error details in /content/VirSorter2/outputs/log/iter-0/step3-classify/provirus-score-dsDNAphage.log
[Tue Oct 17 10:38:12 2023]
Error in rule classify_full_and_part_by_group:
jobid: 59
output: iter-0/dsDNAphage/viral.trim.clf
conda-env: /content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d
shell:

        Log=/content/VirSorter2/outputs/log/iter-0/step3-classify/provirus-score-dsDNAphage.log
        Hallmark_list_f=/content/VirSorter2/db/group/dsDNAphage/hallmark-gene.list
        if [ -s $Hallmark_list_f ]; then
            python /content/VirSorter2/virsorter/./scripts/classify-trimed.py iter-0/dsDNAphage/all.pdg.gff iter-0/dsDNAphage/all.pdg.hmm.tax /content/VirSorter2/db/rbs/rbs-catetory.tsv /content/VirSorter2/db/group/dsDNAphage/model iter-0/viral-combined.fa iter-0/dsDNAphage/viral.trim.clf --group dsDNAphage --hallmark /content/VirSorter2/db/group/dsDNAphage/hallmark-gene.list 2> $Log || { echo "See error details in $Log" | python /content/VirSorter2/virsorter/./scripts/echo.py --level error; exit 1; }
        else
            python /content/VirSorter2/virsorter/./scripts/classify-trimed.py iter-0/dsDNAphage/all.pdg.gff iter-0/dsDNAphage/all.pdg.hmm.tax /content/VirSorter2/db/rbs/rbs-catetory.tsv /content/VirSorter2/db/group/dsDNAphage/model iter-0/viral-combined.fa iter-0/dsDNAphage/viral.trim.clf --group dsDNAphage 2> $Log || { echo "See error details in $Log" | python /content/VirSorter2/virsorter/./scripts/echo.py --level error; exit 1; }
        fi

        
    (one of the commands exited with non-zero exit code; note that snakemake uses bash strict mode!)

Exiting because a job execution failed. Look above for error message

*** An error occurred. Detailed errors may not be printed for certain rules. Refer to the log file of the failed command for troubleshooting
Issues can be raised at: https://github.com/jiarong/VirSorter2/issues
Or send an email to virsorter2 near gmail.com if you do not use GitHub

@TiAmoTYX
Copy link
Author

Hi,how can i fix it?

@TiAmoTYX
Copy link
Author

Log=/content/VirSorter2/outputs/log/iter-0/step3-classify/provirus-score-ssDNA.log

Traceback (most recent call last):
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 275, in
main()
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 1157, in call
return self.main(*args, **kwargs)
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 271, in main
clf_trim_ins.load_data()
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 82, in load_data
indice = [ int(i) for i in indice ]
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 82, in
indice = [ int(i) for i in indice ]
ValueError: invalid literal for int() with base 10: 'Scaffol'

@TiAmoTYX
Copy link
Author

Log=/content/VirSorter2/outputs/log/iter-0/step3-classify/provirus-score-dsDNAphage.log

Traceback (most recent call last):
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 275, in
main()
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 1157, in call
return self.main(*args, **kwargs)
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/content/VirSorter2/db/conda_envs/68f94c41bd29d12e5ee0ead52425fb8d/lib/python3.8/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 271, in main
clf_trim_ins.load_data()
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 82, in load_data
indice = [ int(i) for i in indice ]
File "/content/VirSorter2/virsorter/./scripts/classify-trimed.py", line 82, in
indice = [ int(i) for i in indice ]
ValueError: invalid literal for int() with base 10: 'Scaffol'

@TiAmoTYX
Copy link
Author

My Fasta file data format is:

ComND.Nov_Scaffold1 flag=0 multi=153.0944 len=251320
CTGTGAGGAGCAGCGTAATCCCTGCGGCAATCATGGCTTGGCGGAAGATTATTCTCATGT

@jiarong
Copy link
Owner

jiarong commented Oct 18, 2023

Hi, you are pretty close to finding the issue. Fasta format require the header line to start with ">".

@TiAmoTYX
Copy link
Author

Hi,
I have found the problem. The data format after my ">" has an item called 'Scaffold', and deleting this item will solve the problem. Thank you for your work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants