TypeError: batch_run_sample() takes from 16 to 17 positional arguments but 18 were given
解决使用cnvkit运行中出现的报错。
我在使用CNVkit 0.9.11.dev0处理输入为bam文件时,遇到该报错
CNVkit 0.9.11.dev0
Wrote /public/home/result/GRCh37_cnvkit_filtered_ref.target-tmp.bed with 565907 regions
Wrote /public/home/result/GRCh37_cnvkit_filtered_ref.antitarget-tmp.bed with 0 regions
Running 1 samples in serial
Traceback (most recent call last):
File "/public/home/chengjing2/miniconda3/envs/ecDNA/bin/cnvkit.py", line 8, in <module>
sys.exit(main())
File "/public/home/chengjing2/taozy/tools/cnvkit/cnvlib/cnvkit.py", line 10, in main
args.func(args)
File "/public/home/chengjing2/taozy/tools/cnvkit/cnvlib/commands.py", line 205, in _cmd_batch
pool.submit(
File "/public/home/chengjing2/taozy/tools/cnvkit/cnvlib/parallel.py", line 18, in submit
return SerialFuture(func(*args))
TypeError: batch_run_sample() takes from 16 to 17 positional arguments but 18 were given
最后发现该报错是版本问题,不要使用0.9.11.dev0版本来安装,使用0.9.10版本即可。
wget https://github.com/etal/cnvkit/archive/refs/tags/v0.9.10.tar.gz
tar -xvf v0.9.10.tar.gz
cd cnvkit-0.9.10/
pip install -e .
使用源码安装注意同时在环境下安装r和r包DNAcopy。