提交 ff5d1fcc authored 作者: Frederic's avatar Frederic

not set unexisting attribute

上级 311ebf1d
......@@ -18,7 +18,7 @@ def get_mode(gpu):
'local_gpu_multinomial')
if isinstance(mode.linker, theano.gof.PerformLinker):
mode.linker = predefined_linkers['c|py']
if not getattr(mode.linker, 'c_thunks', True):
if hasattr(mode.linker, 'c_thunks'):
mode.linker.c_thunks = True
return mode
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论