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

Fix GpuConv error reporting. The error was raised in the next executed apply…

Fix GpuConv error reporting. The error was raised in the next executed apply node when we detect the input to be None instead of CudaNdarray. this fixes gh-786.
上级 157526f3
...@@ -652,7 +652,7 @@ class GpuConv(GpuOp): ...@@ -652,7 +652,7 @@ class GpuConv(GpuOp):
def c_code_cache_version(self): def c_code_cache_version(self):
# raise this whenever modifying any of the support_code_files # raise this whenever modifying any of the support_code_files
return (0, 19) return (0, 20)
def c_support_code_apply(self, node, nodename): def c_support_code_apply(self, node, nodename):
# REMEMBER TO RAISE c_code_cache_version when changing any of # REMEMBER TO RAISE c_code_cache_version when changing any of
...@@ -711,6 +711,10 @@ class GpuConv(GpuOp): ...@@ -711,6 +711,10 @@ class GpuConv(GpuOp):
%(max_threads_dim0)s); %(max_threads_dim0)s);
Py_XDECREF(%(out)s); Py_XDECREF(%(out)s);
%(out)s = out2; %(out)s = out2;
if (%(out)s==NULL){
%(fail)s
}
""" % sub """ % sub
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论