提交 11c16dfe 编写于 作者: S SunAhong1993

fix the bug

上级 ca3708c3
...@@ -47,8 +47,6 @@ def normalize_layer(input, ...@@ -47,8 +47,6 @@ def normalize_layer(input,
scale_attr = fluid.ParamAttr(name=param_prefix + '_scale') scale_attr = fluid.ParamAttr(name=param_prefix + '_scale')
scale_param = fluid.layers.create_parameter( scale_param = fluid.layers.create_parameter(
shape=shape, dtype=input.dtype, name=name, attr=scale_attr) shape=shape, dtype=input.dtype, name=name, attr=scale_attr)
scale_param = fluid.layers.reshape(x=scale_param, \
shape=[1] if channel_shared else [input_shape[0][1]])
out = fluid.layers.elementwise_mul( out = fluid.layers.elementwise_mul(
x=l2_norm, y=scale_param, axis=-1 if channel_shared else 1) x=l2_norm, y=scale_param, axis=-1 if channel_shared else 1)
return out return out
......
...@@ -32,7 +32,7 @@ def priorbox_layer(inputs, ...@@ -32,7 +32,7 @@ def priorbox_layer(inputs,
name, name,
min_size, min_size,
max_size=None, max_size=None,
aspect_ratio=None, aspect_ratio=1.0,
variance=[0.1, 0.1, 0.2, 0.2], variance=[0.1, 0.1, 0.2, 0.2],
flip=False, flip=False,
clip=False, clip=False,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册