linzhi2013 / MitoZ

MitoZ: A toolkit for assembly, annotation, and visualization of animal mitochondrial genomes
https://doi.org/10.1093/nar/gkz173
GNU General Public License v3.0
115 stars 39 forks source link

Hi, I got an error in visualize step. #98

Closed paul-bio-hh closed 3 years ago

paul-bio-hh commented 3 years ago

Hello.

I have two 9Gb of trimmed fastq files. As there were no need to filter, I ran a all2 step. And error popped up, so I searched same situations. And figured it as below.

$ MitoZ/bin/assemble/mitoAssemble all -K 71 -o work71 -s work71.soaptrans.lib -p 32 _(work71.soaptrans.lib in the temp.xxx/xxx.assembly)_ $MitoZ.py findmitoscaf --genetic_code 5 --clade Mollusca --from_soaptrans --fastafile work71.scafSeq --thread_number 8 --outprefix O-2 Everything worked well so far. However I got stuck in annotate step... $MitoZ.py annotate --genetic_code 5 --clade Mollusca --outprefix O-2 --thread_number 8 --fastafile O-2.mitogenome.fa --topology circular _(in the O-2.mitogeneme.fa, ">C55511 topology=circular" was written. So I used --topology circular option. Is it right?)_ and got this error message Traceback (most recent call last): File "/NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/annotate/gene_feature.py", line 48, in read_fastaLike2 raise StopIteration StopIteration The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/annotate/find_contro_region.py", line 364, in main() File "/NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/annotate/find_contro_region.py", line 254, in main all_seqid_geneCoor = read_featureTable(fea_files=args.fea_files) File "/NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/annotate/find_contro_region.py", line 109, in read_featureTable seqid_geneCoor = get_gene_coor(fea_f) File "/NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/annotate/gene_feature.py", line 62, in get_gene_coor for rec in records: RuntimeError: generator raised StopIteration Error occured when running command: /home/creo9447/miniconda3/envs/mitozEnv/bin/python3 /NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/annotate/find_contro_region.py -fa_file /NFS/users/creo9447/project/ONF/3_assembly/mitoz/O-2/practice-node01/2-findmitoscaf/O-2.result/O-2.mitogenome.fa -PCG_cutoff_file /NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/profiles/CDS_HMM/Mollusca_CDS_length_list -PCG_len_ratio 0.9 -s_rRNA_CM_file /NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/profiles/rRNA_CM/v1.1_12snew.cm -l_rRNA_CM_file /NFS/users/creo9447/software/MitoZ/release_MitoZ_v2.3/bin/profiles/rRNA_CM/v1.1_16snew.cm -rRNA_len_ratio 0.9 -tRNA_num_min 22 -fea_files O-2_mitoscaf.fa.cds.ft /NFS/users/creo9447/project/ONF/3_assembly/mitoz/O-2/practice-node01/3-2/tmp/O-2.annotation/O-2_mitoscaf.fa.trna.ft O-2_mitoscaf.fa.s-rRNA.ft O-2_mitoscaf.fa.l-rRNA.ft -CR_len_min 600 -outfile O-2_mitoscaf.fa.control_region.ft can you give me solution?
linzhi2013 commented 3 years ago

The problem

raise StopIteration StopIteration

seems caused by Python version difference, e.g. https://stackoverflow.com/questions/51700960/runtimeerror-generator-raised-stopiteration-every-time-i-try-to-run-app.

Please refer to https://github.com/linzhi2013/MitoZ/issues/89 first.

Cheers

paul-bio-hh commented 3 years ago

I finally have result from annotation now! thank you linzhi! I have some questions.

  1. After the annotation step I thought I had to do visualize, however, in the annotation result, there were circos picture already. So this means I do not have to run visualize step?

  2. Can I do MitoZ with RNA sequence?

  3. As I have Circos.png, can I say that I get this result from circos?

linzhi2013 commented 3 years ago
  1. yes, there will be a circos plot after annotation. you can run visualize again if you like (e.g. add the fastq files to calculate sequencing depth along the mitogenome)

  2. Yes you can try. But maybe it would not get very good results

  3. Yes. but the Perl Circos module itself is unable to draw the PNG for you. MitoZ is mainly coded with Python, so could people conclude that "we assembled and annotated the mitogenome with Python"? Maybe "yes" in some sense, but the algorithms for finishing this job is not part of Python.

paul-bio-hh commented 3 years ago

Hi Linzhi. Me again. With your help, I did get the result from circos. Without you, I might be in troble.... Thanks again.

As my data was produced by assemle --run_mode 2, I had 6 missing PCGs. Therefore, I decided to do more analysis with --run_mode 3

everything was fine so far, but I have some question.

  1. k31.mitogeneome.fa image

  2. k91.mitogenome.fa image

  3. circos result image

this is the result from Multi-Kmer. as you can see, In the K31, I could find circular topolgy whereas none circular topolgies are in K91. And my understanding is that multi kmer step use those two result to make missing PSGs in the circos right?

However in the circos result, there were 3 COX1 in seperated scaffolds, and 4 COX3 seperated... How could I solve this problem?

linzhi2013 commented 3 years ago

Hello there,

Please raise a new issue, since this is not related to the original problem. Thanks!

image