提交 178ae035 authored 作者: affanv14's avatar affanv14

remove assert in get_conv_grad*

上级 7eb53fc2
...@@ -184,7 +184,6 @@ def get_conv_gradweights_shape(image_shape, top_shape, ...@@ -184,7 +184,6 @@ def get_conv_gradweights_shape(image_shape, top_shape,
if filter_dilation is None: if filter_dilation is None:
filter_dilation = np.ones(len(subsample), dtype='int') filter_dilation = np.ones(len(subsample), dtype='int')
if num_groups > 1: if num_groups > 1:
assert len(subsample) == 2
nchan = nchan // num_groups nchan = nchan // num_groups
if isinstance(border_mode, tuple): if isinstance(border_mode, tuple):
...@@ -295,7 +294,6 @@ def get_conv_gradinputs_shape(kernel_shape, top_shape, ...@@ -295,7 +294,6 @@ def get_conv_gradinputs_shape(kernel_shape, top_shape,
if filter_dilation is None: if filter_dilation is None:
filter_dilation = np.ones(len(subsample), dtype='int') filter_dilation = np.ones(len(subsample), dtype='int')
if num_groups > 1: if num_groups > 1:
assert len(subsample) == 2
nkern = nkern * num_groups nkern = nkern * num_groups
if isinstance(border_mode, tuple): if isinstance(border_mode, tuple):
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论