未验证 提交 e233b91a 编写于 作者: J Jiabin Yang 提交者: GitHub

test=develop, fix using create_parameter with attr set to False error (#16115)

上级 5bde1202
...@@ -270,6 +270,9 @@ class LayerHelperBase(object): ...@@ -270,6 +270,9 @@ class LayerHelperBase(object):
attr = copy.deepcopy(attr) attr = copy.deepcopy(attr)
if attr is None: if attr is None:
attr = ParamAttr._to_attr(attr) attr = ParamAttr._to_attr(attr)
if not attr:
return None
assert isinstance(attr, ParamAttr) assert isinstance(attr, ParamAttr)
suffix = 'b' if is_bias else 'w' suffix = 'b' if is_bias else 'w'
if attr.name is None: if attr.name is None:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册