Commit 9c2e0441 authored by Yong Tang's avatar Yong Tang Committed by Jonathan Hseu
Browse files

Check input dimension for contrib.layers.conv2d/conv3d (#18251)



* Check input dimension for contrib.layers.conv2d/conv3d

This fix tries to fix the issue raised in 14583 where
the input dimension was not checked for contrib.layers.conv2d/conv3d
and contrib.slim.conv2d/conv3d.

The issue was that conv2d/conv3d were just aliases of
convolution. This fix wrap the conv2d/conv3d with the input
dimension check so that incorrect usage will return ValueError.

This fix fixes 14583.

Signed-off-by: default avatarYong Tang <yong.tang.github@outlook.com>

* Add test case for conv2d/conv3d shape check

Signed-off-by: default avatarYong Tang <yong.tang.github@outlook.com>

* Fix impacted tests.

Signed-off-by: default avatarYong Tang <yong.tang.github@outlook.com>

* Update convolution instead of adding _convolution,

based on review feedback

Signed-off-by: default avatarYong Tang <yong.tang.github@outlook.com>

* Add convolution1d and additional update

Signed-off-by: default avatarYong Tang <yong.tang.github@outlook.com>
parent 41308f45
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment