TF-Chan-Lab / miRDeep-P2_pipeline

GNU General Public License v3.0
5 stars 1 forks source link

miRDP2-v1.1.4_pipeline.bash index error #3

Open malvaceae3 opened 1 year ago

malvaceae3 commented 1 year ago

I am trying to run miRDeep-P2 using miRDP2-v1.1.4_pipeline.bash. miRDP2-v1.1.4_pipeline.bash -g ref.fa -x ref.fa -q -b fastq_list.txt -o ./result

Then I got the error in script_err file. I really appreciate if you give me some advises.

# The error messages in script_err file

Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
Could not locate a Bowtie index corresponding to basename "/lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/index/rfam_index"
Command: /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/bowtie-align-s --wrapper basic-0 -v 0 -f /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/index/rfam_index ./result/*****.unpaired.trimmed.fastq.gz.min19max25.ori.fa 
Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
stat: No such file or directory
Warning: Could not open read file "./result/*****.unpaired.trimmed.fastq.gz.min19max25.ori.fa" for reading; skipping...
alanlamsiu commented 1 year ago

Hi @malvaceae3~ It seems to me that the bowtie index of ref.fa and some files speficifed in fastq_list.txt are missing. Could you double check and show where you put the bowtie index files and the contents in fastq_list.txt so that we can better understand the situation?

malvaceae3 commented 1 year ago

Thank you very much for your help. I put the bowtie index files in same directory I work on the command. The contents in fastq_list.txt are in different directory, but I wrote the absolute path of the files in fastq_list.txt.

alanlamsiu commented 1 year ago

Let's say the .fasta file of the reference is ref.fa. You should have the bowtie index files ref.fa.1.ebwt, ref.fa.2.ebwt, ref.fa.3.ebwt, ref.fa.4.ebwt, ref.fa.rev.1.ebwt, and ref.fa.rev.2.ebwt. The index being passed to miRDP2 should be ref.fa, instead of the directory "/lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/index/rfam_index" according to the error message.

malvaceae3 commented 1 year ago

Thank you. I wrote the index path after -x option like this, but I got the same error. I have reference.fasta.1.ebwt... in the passed directory.

miRDP2-v1.1.4_pipeline.bash -g /lustre7/home/*****/Analysis/*****/reference.fasta \
                            -x /lustre7/home/*****/Analysis/*****/reference.fasta \
                            -q -b ./fastq_list.txt -o ./result
malvaceae3 commented 1 year ago

In the manual pdf, I found that I need to set up rfam_index in ~~~/mirdeep-p2/bin/scripts/index directory. I set up rfam_index and convert input fastq file to fasta file, then the pipeline worked.

But I cannot get prediction file because of unable to read file magic number...

# The error messages in script_err file

Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
# reads processed: 14305611
# reads with at least one alignment: 7055286 (49.32%)
# reads that failed to align: 7250325 (50.68%)
Reported 7055286 alignments
Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
# reads processed: 14305611
# reads with at least one alignment: 86056 (0.60%)
# reads that failed to align: 14219555 (99.40%)
Reported 86056 alignments
Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
# reads processed: 0
# reads with at least one alignment: 0 (0.00%)
# reads that failed to align: 0 (0.00%)
No alignments
Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
# reads processed: 1
# reads with at least one alignment: 0 (0.00%)
# reads that failed to align: 1 (100.00%)
No alignments
Unable to read file magic number
Warning: Empty input file
Error: No unambiguous stretches of characters in the input.  Aborting...
Command: bowtie-build --wrapper basic-0 -f ./result/*****.unpaired.trimmed.fastq.gz.min19max25.fastq/*****.unpaired.trimmed.fastq.gz.min19max25.fastq_precursors.fa ./result/*****.unpaired.trimmed.fastq.gz.min19max25.fastq/index/*****.unpaired.trimmed.fastq.gz.min19max25.fastq_precursors 
Setting the index via positional argument will be deprecated in a future release. Please use -x option instead.
Could not locate a Bowtie index corresponding to basename "./result/*****.unpaired.trimmed.fastq.gz.min19max25.fastq/index/*****.unpaired.trimmed.fastq.gz.min19max25.fastq_precursors"
Command: /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/bowtie-align-s --wrapper basic-0 -a -v 0 -f ./result/*****.unpaired.trimmed.fastq.gz.min19max25.fastq/index/*****.unpaired.trimmed.fastq.gz.min19max25.fastq_precursors ./result/*****.unpaired.trimmed.fastq.gz.min19max25.fastq/*****.unpaired.trimmed.fastq.gz.min19max25.fastq_filtered.fa 

I also got error in filename.err.

Illegal division by zero at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/preprocess_reads.pl line 67.
Use of uninitialized value $id in hash element at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/convert_bowtie_to_blast.pl line 89.
Use of uninitialized value $id in hash element at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/convert_bowtie_to_blast.pl line 89.
Use of uninitialized value $id in hash element at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/mod-miRDP.pl line 1222.
Use of uninitialized value $id in hash element at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/mod-miRDP.pl line 1223.
Use of uninitialized value $id in hash element at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/mod-miRDP.pl line 1224.
Use of uninitialized value $id in hash element at /lustre7/home/*****/miniconda3/envs/mirdeep-p2/bin/scripts/mod-miRDP.pl line 1225.
Use of uninitialized value ...
malvaceae3 commented 1 year ago

After I formatted input fasta files properly, the errors were resolved. Thank you very much for your help!

alanlamsiu commented 1 year ago

Good to know about it.

malvaceae3 commented 1 year ago

Is it possible to create gff/gtf annotation file for mature miRNA sequences obtained from miRDP2? I'm sorry for asking so many questions. Thank you for your kind help.

alanlamsiu commented 1 year ago

I think such information is not intuitive to me in the outputs from miRDP2. If you have a list of miRNAs that you are interested in, I would recommend to blast the sequences against reference genome. A gff/gtf annotation should be easily generated from the table output from blast because it already contains all necessary information.

malvaceae3 commented 1 year ago

Thank you for your kind advice. I will try it.

aayoungfish commented 1 year ago

After I formatted input fasta files properly, the errors were resolved. Thank you very much for your help!

I have the same error as you mentioned above, I would like to ask how you formatted your input fasta file correctly? The fasta file I entered appears to be in the correct format. Thank you!

malvaceae3 commented 1 year ago

Hi @aayoungfish I formatted the input fasta file following the manual of miRDP2. https://srnaworld.com/miRDP2/index.html After visiting this URL, you can find manual under the directory of version 1.1.4 of the download site.

You can find the format in "3.1 FORMATTING READS" in the manual.

aayoungfish commented 1 year ago

Hi @aayoungfish I formatted the input fasta file following the manual of miRDP2. https://srnaworld.com/miRDP2/index.html After visiting this URL, you can find manual under the directory of version 1.1.4 of the download site.

You can find the format in "3.1 FORMATTING READS" in the manual.

It works!!! Thank you so much!