提交 b9e32a0b authored 作者: Ramana.S's avatar Ramana.S

Suggested changes made

上级 d4128b7d
......@@ -5,7 +5,7 @@ from theano.tensor.nnet.abstract_conv import get_conv_output_shape
class TestGetConvOutShape(unittest.TestCase):
def test_basic(self):
image_shape, kernel_shape = (3, 2, 8, 8), (4, 2, 5, 5)
image_shape, kernel_shape = (3, 2, 8, 9), (4, 2, 5, 6)
sub_sample = (1, 2)
test1_params = get_conv_output_shape(
image_shape, kernel_shape, 'valid', sub_sample)
......@@ -13,6 +13,10 @@ class TestGetConvOutShape(unittest.TestCase):
image_shape, kernel_shape, 'half', sub_sample)
test3_params = get_conv_output_shape(
image_shape, kernel_shape, 'full', sub_sample)
test4_params = get_conv_output_shape(
image_shape, kernel_shape, (1, 2), sub_sample)
self.assertTrue(test1_params == (3, 4, 4, 2))
self.assertTrue(test2_params == (3, 4, 8, 4))
self.assertTrue(test3_params == (3, 4, 12, 6))
self.assertTrue(test2_params == (3, 4, 8, 5))
self.assertTrue(test3_params == (3, 4, 12, 7))
self.assertTrue(test4_params == (3, 4, 6, 4))
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论