comprna / METEORE

Automatic DNA methylation detection from nanopore tools and their consensus model
MIT License
72 stars 18 forks source link

Fail with Nanopolish pipeline #3

Closed lanyelin1123 closed 3 years ago

lanyelin1123 commented 3 years ago

Hi, I already had run the nanopolish pipeline successfully. Today I want to try it again, and I had removed the output files which from last test. But I failed in the step of minimap2:

`(meteore_nanopolish_env) root@iZbp1g75dkmfozg1lmq072Z:~/lyl/METEORE# snakemake -s Nanopolish nanopolish_results/example_nanopolish-freq-perCG.tsv --cores all Building DAG of jobs... Using shell: /bin/bash Provided cores: 1 (use --cores to define parallelism) Rules claiming more threads will be scaled down. Conda environments: ignored Job counts: count jobs 1 calculate_frequency 1 call_methylation 1 index 1 minimap2 1 samtools_index 1 samtools_sort 1 split_cpgs 7 Select jobs to execute...

[Mon Dec 14 19:33:14 2020] rule index: input: data/example, example.fastq output: example.fastq.index, example.fastq.index.fai, example.fastq.index.gzi, example.fastq.index.readdb jobid: 6 wildcards: sample=example

[readdb] indexing data/example [readdb] num reads: 50, num reads with path to fast5: 50 [Mon Dec 14 19:33:14 2020] Finished job 6. 1 of 7 steps (14%) done Select jobs to execute...

[Mon Dec 14 19:33:14 2020] rule minimap2: input: data/ecoli_k12_mg1655.fasta, example.fastq output: nanopolish_results/mapped/example.bam log: nanopolish_results/mapped/example.log jobid: 4 wildcards: sample=example

[Mon Dec 14 19:33:23 2020] Error in rule minimap2: jobid: 4 output: nanopolish_results/mapped/example.bam log: nanopolish_results/mapped/example.log (check log file(s) for error message)

RuleException: URLError in line 25 of /root/lyl/METEORE/Nanopolish: <urlopen error [Errno 111] Connection refused> File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/site-packages/snakemake/executors/init.py", line 2318, in run_wrapper File "/root/lyl/METEORE/Nanopolish", line 25, in rule_minimap2 File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 214, in urlopen File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 523, in open File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 632, in http_response File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 555, in error File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 494, in _call_chain File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 747, in http_error_302 File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 517, in open File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 534, in _open File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 494, in _call_chain File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 1385, in https_open File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/urllib/request.py", line 1345, in do_open File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/site-packages/snakemake/executors/init.py", line 560, in _callback File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/concurrent/futures/thread.py", line 52, in run File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/site-packages/snakemake/executors/init.py", line 546, in cached_or_run File "/root/anaconda3/envs/meteore_nanopolish_env/lib/python3.9/site-packages/snakemake/executors/init__.py", line 2349, in run_wrapper Shutting down, this might take some time. Exiting because a job execution failed. Look above for error message Complete log: /root/lyl/METEORE/.snakemake/log/2020-12-14T193314.025215.snakemake.log ` I have no idea how to deal with this. Thanks in advance!!

zakayuen commented 3 years ago

Hi,

It may be due to the version of the Snakemake that you are using. Could you remove the existing environment and create it again with the specified version of Snakemake?

conda remove --name meteore_nanopolish_env --all mamba create -c conda-forge -c bioconda -n meteore_nanopolish_env snakemake==5.26.1 conda activate meteore_nanopolish_env mamba install -c bioconda nanopolish samtools r-data.table r-dplyr r-plyr

Make sure the output files from the last run were removed. Then rerun the snakemake: snakemake -s Nanopolish nanopolish_results/example_nanopolish-freq-perCG.tsv --cores all

Let me know how it goes.

Zaka

zakayuen commented 3 years ago

Hi @lanyelin1123,

Now you can install required packages for Nanopolish pipeline using nanopolish.yml file. Please run it again. It should work now.

Zaka