hzi-bifo / RiboDetector

Accurate and rapid RiboRNA sequences Detector based on deep learning
GNU General Public License v3.0
94 stars 16 forks source link

Tuple range error #44

Closed mwylerCH closed 6 months ago

mwylerCH commented 7 months ago

Thanks for developing RiboDetector. I installed it today using conda (as described) in the cpu mode:

conda create -n ribodetector python=3.8
conda activate ribodetector
conda install -c bioconda ribodetector

Once I'm running it, it start well with the following stdout:

ribodetector_cpu -t 20 \
  -l 124 \
  -i RAW.R1.fq.gz RAW.R2.fq.gz \
  -e norrna \
  --chunk_size 1024 \
  -o noRibo.R1.fq.gz noRibo.R2.fq.gz

2023-12-21 15:00:40 : INFO  Using high RECALL model
2023-12-21 15:00:40 : INFO  Log file: None
2023-12-21 15:00:40 : INFO  Classify paired-end reads with chunk size 1024
2023-12-21 15:00:40 : INFO  Writing output non-rRNA sequences into file: noRibo.R1.fq.gz noRibo.R2.fq.gz

But once it starts to write out the files I get these error messages:

Traceback (most recent call last):
  File "/home/mwyler/miniconda3/envs/ribodetector/bin/ribodetector_cpu", line 10, in <module>
    sys.exit(main())
  File "/home/mwyler/miniconda3/envs/ribodetector/lib/python3.8/site-packages/ribodetector/detect_cpu.py", line 822, in main
    seq_pred.detect()
  File "/home/mwyler/miniconda3/envs/ribodetector/lib/python3.8/site-packages/ribodetector/detect_cpu.py", line 599, in detect
    self.run_with_chunks()
  File "/home/mwyler/miniconda3/envs/ribodetector/lib/python3.8/site-packages/ribodetector/detect_cpu.py", line 435, in run_with_chunks
    self.logger.info('{}{}{}{} reads finished!'.format(
IndexError: Replacement index 3 out of range for positional args tuple

Please let me know if you need further informations. Greetings

dawnmy commented 7 months ago

Thank you reporting this, it seems there is an error in the version 0.2.9. Will release a quick fix in the next two days. Before that you could try version 0.2.8

dawnmy commented 6 months ago

@mwylerCH Fixed this issue in version 0.3.0. You can install it with pip. It will be available via conda one day later.

mwylerCH commented 6 months ago

Works through, many thanks for the quick update.