提交 7b206fb7 authored 作者: Pascal Lamblin's avatar Pascal Lamblin

Disable average_exc_pad pooling for cudnn v3

See #3776
上级 adf81d30
......@@ -1401,6 +1401,9 @@ class GpuDnnPoolDesc(GpuOp):
raise RuntimeError("CuDNN pooling with padding requires CuDNN v2")
if self.get_ndim() == 3 and version() < (3000, 3000):
raise RuntimeError("CuDNN 3d pooling requires CuDNN v3")
if mode == 'average_exc_pad' and version() < (4004, 4004):
raise RuntimeError(
"CuDNN pooling mode 'average_exc_pad' requires at least v4")
def get_ndim(self):
return len(self.ws)
......
......@@ -953,6 +953,9 @@ class GpuDnnPoolDesc(Op):
if self.get_ndim() == 3 and version() < 3000:
raise RuntimeError("CuDNN 3d pooling requires v3")
if mode == 'average_exc_pad' and version() < 4004:
raise RuntimeError(
"CuDNN pooling mode 'average_exc_pad' requires at least v4")
def get_ndim(self):
return len(self.ws)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论