提交 333d471a authored 作者: jiakai's avatar jiakai

well, it is cross correlation, not conv

上级 e8fe4ad0
...@@ -837,11 +837,20 @@ class TestConvWithPadding(object): ...@@ -837,11 +837,20 @@ class TestConvWithPadding(object):
note that in order to make the yield work, we can not subclass from note that in order to make the yield work, we can not subclass from
unittest.TestCase unittest.TestCase
""" """
conv_ops = [lambda i, k, border_mode:
theano.sandbox.cuda.blas.GpuCorrMM(border_mode=border_mode)(i, k)] @staticmethod
def gemm_conv_op(img, kern, border_mode):
kern = theano.sandbox.cuda.basic_ops.gpu_contiguous(
kern[:, :, ::-1, ::-1])
y = theano.sandbox.cuda.blas.GpuCorrMM(border_mode=border_mode)(
img, kern)
return y
conv_ops = []
@classmethod @classmethod
def setup_class(cls): def setup_class(cls):
cls.conv_ops.append(cls.gemm_conv_op)
if cuda.dnn.dnn_available(): if cuda.dnn.dnn_available():
cls.conv_ops.append(cuda.dnn.dnn_conv) cls.conv_ops.append(cuda.dnn.dnn_conv)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论