abricate icon indicating copy to clipboard operation
abricate copied to clipboard

Results are not reproducible

Open haruosuz opened this issue 5 years ago • 3 comments
trafficstars

I wonder if it is possible to make results reproducible using abricate.

Different results were sometimes produced when the same command was run several times.

abricate --threads 80 --db megares plasmid.1.1.genomic.fna > plasmid.1.1.genomic.fna.megares.abricate.txt

Here is an example of different results:

diff test1/plasmid.1.1.genomic.fna.megares.abricate.txt test2/plasmid.1.1.genomic.fna.megares.abricate.txt

> plasmid.1.1.genomic.fna.filtered.fa    NZ_CP011632.1   45350   45697  +
        QACEDELTA1      1-348/348       =============== 0/0     100.00  100.00  megares MEG_5829        Multi-compound:Drug_and_biocide_resistance:Drug_and_biocide_SMR_efflux_pumps:QACEDELTA1 
3340d3340

< plasmid.1.1.genomic.fna.filtered.fa    NZ_CP014072.1   31265   31612  +
        QACEDELTA1      1-348/348       =============== 0/0     100.00  100.00  megares MEG_5829        Multi-compound:Drug_and_biocide_resistance:Drug_and_biocide_SMR_efflux_pumps:QACEDELTA1 

#FILE   SEQUENCE        START   END     STRAND  GENE    COVERAGE        COVERAGE_MAP    GAPS    %COVERAGE       %IDENTITY       DATABASE        ACCESSION       PRODUCT RESISTANCE

The FASTA files were downloaded using:

wget ftp://ftp.ncbi.nlm.nih.gov/refseq/release/plasmid/plasmid.*.1.genomic.fna.gz

haruosuz avatar Sep 23 '20 14:09 haruosuz

Hi @haruosuz did you sort before your diff? Because you are running it with 80 threads, it will add the results to the files in the same order as they are received, which may differ slightly between runs.

In bash you can do the following:

diff <(sort test1/plasmid.1.1.genomic.fna.megares.abricate.txt) <(sort test2/plasmid.1.1.genomic.fna.megares.abricate.txt)

If your shell is not bash, you can run the following:

bash -c 'diff <(sort test1/plasmid.1.1.genomic.fna.megares.abricate.txt) <(sort test2/plasmid.1.1.genomic.fna.megares.abricate.txt)'

If the error persists, can you run with --debug and send us the log, along with the version of abricate you are using?

Thank you.

andersgs avatar Sep 23 '20 17:09 andersgs

Dear @andersgs Thank you for your reply.

diff <(sort test1/plasmid.1.1.genomic.fna.megares.abricate.txt) <(sort test2/plasmid.1.1.genomic.fna.megares.abricate.txt)

printed the same messages.

Attached is a log generated by running abricate version 1.0.1 with --debug. log_5073294.zip

The number of the hit sequences sometimes varied slightly from test to test as follows:

$wc -l */*.txt

    5485 test1/plasmid.1.1.genomic.fna.megares.abricate.txt
    5485 test2/plasmid.1.1.genomic.fna.megares.abricate.txt
    5486 test3/plasmid.1.1.genomic.fna.megares.abricate.txt
    5486 test4/plasmid.1.1.genomic.fna.megares.abricate.txt

haruosuz avatar Sep 24 '20 06:09 haruosuz

Thank you @haruosuz. We are looking in to it.

andersgs avatar Sep 24 '20 18:09 andersgs