2017-05-31 157 views
0

我想运行程序genipe做一些全基因组生存分析。我已经安装genipe和所有相关的目录。然而,当我去运行程序出现错误:Python程序“genipe” - TypeError:__init __()得到了一个意想不到的关键字参数'正常化'

“类型错误:_ 初始化 _()得到了一个意想不到的关键字参数‘正常化’”

我没有任何编辑的genipe的脚本和我运行genipe没有问题在不同的服务器上,所以我不知道什么是错的!任何帮助将不胜感激。

非常感谢,

卡拉

编辑: 我使用Python 3.6.1版

回溯如下:

Traceback (most recent call last): 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 119, in worker 
    result = (True, func(*args, **kwds)) 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 44, in mapstar 
    return list(map(*args)) 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 965, in process_impute2_site 
    use_ml=site_info.use_ml, 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 1048, in fit_cox 
    cf = CoxPHFitter(alpha=0.95, tie_method="Efron", normalize=False) 
TypeError: __init__() got an unexpected keyword argument 'normalize' 
""" 

The above exception was the direct cause of the following exception: 

Traceback (most recent call last): 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 811, in compute_statistics 
    for result in pool.map(process_impute2_site, sites_to_process): 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 260, in map 
    return self._map_async(func, iterable, mapstar, chunksize).get() 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 608, in get 
    raise self._value 
TypeError: __init__() got an unexpected keyword argument 'normalize' 

[2017-05-31 14:18:53 ERROR] __init__() got an unexpected keyword argument 'normalize' 
multiprocessing.pool.RemoteTraceback: 
""" 
Traceback (most recent call last): 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 119, in worker 
    result = (True, func(*args, **kwds)) 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 44, in mapstar 
    return list(map(*args)) 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 965, in process_impute2_site 
    use_ml=site_info.use_ml, 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 1048, in fit_cox 
    cf = CoxPHFitter(alpha=0.95, tie_method="Efron", normalize=False) 
TypeError: __init__() got an unexpected keyword argument 'normalize' 
""" 

The above exception was the direct cause of the following exception: 

Traceback (most recent call last): 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/bin/imputed-stats", line 11, in <module> 
    sys.exit(main()) 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 161, in main 
    options=args, 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tools/imputed_stats.py", line 811, in compute_statistics 
    for result in pool.map(process_impute2_site, sites_to_process): 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 260, in map 
    return self._map_async(func, iterable, mapstar, chunksize).get() 
    File "https://stackoverflow.com/users/k1640238/miniconda/envs/genipe_pyvenv/lib/python3.6/multiprocessing/pool.py", line 608, in get 
    raise self._value 
TypeError: __init__() got an unexpected keyword argument 'normalize' 
+0

为了能够解决这个问题,真的需要整个回溯和你的Python版本。 – obskyr

+0

我编辑过的问题包含了回溯和版本。 – Caragh

回答

1

lifeline changelog这个关键字参数具有判断已从此特定功能中删除。生命线是一个包含这个特殊功能的包,并且是used by genipe

你可以自己安装以前版本的生命线,看看它是否有助于或等待genipe库中的更新。

从您的评论中查看更多的错误,看起来好像是this is problematic code。您正尝试使用dmatrices,但似乎没有定义。可能是因为提到try/catch块找不到statsmodel安装,因此也没有导入patsy

尝试手动安装其他软件包,从

,看看你会得到任何错误,那么......

+0

非常感谢勘误,我会尝试安装以前的版本,看看是否有效。 – Caragh

+0

我已经恢复到以前版本的生命线。但是我仍然有类似的问题。我已经安装了Genipe指令中指定的所有软件包版本。 – Caragh

+0

错误:test_fit_cox_interaction_snp1(genipe.tests.test_imputed_stats.TestImputedStatsCox) 使用交互,第一个SNP测试'fit_cox'函数。 回溯(最近通话最后一个): 文件 “/miniconda/envs/genipe_pyvenv/lib/python3.6/site-packages/genipe/tests/test_imputed_stats.py”,线路866,在test_fit_cox_interaction_snp1 公式=公式, 文件“/ miniconda/envs/genipe_pyvenv/lib/python3。6/site-packages/genipe/tools/imputed_stats.py“,第1128行,in fit_cox y,X = dmatrices(公式,data = data,return_type =”dataframe“) NameError:名称'dmatrices'未定义 – Caragh

0

见勘误的答案在上面,我使用了一些依赖关系的错误版本,但即使如此,该程序仍然给我错误。但是当我恢复到python 3.4时,该程序起作用。

相关问题