From 7db017b0b8e758f19046821435bc75ae913040f7 Mon Sep 17 00:00:00 2001 From: xiongkun Date: Wed, 31 Aug 2022 14:15:40 +0800 Subject: [PATCH] fix bugs (#45551) --- .../paddle/fluid/dygraph/dygraph_to_static/convert_operators.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/paddle/fluid/dygraph/dygraph_to_static/convert_operators.py b/python/paddle/fluid/dygraph/dygraph_to_static/convert_operators.py index aa870968695..85eaa3da33b 100644 --- a/python/paddle/fluid/dygraph/dygraph_to_static/convert_operators.py +++ b/python/paddle/fluid/dygraph/dygraph_to_static/convert_operators.py @@ -32,7 +32,7 @@ def convert_attr(x, attr): if isinstance(x, Variable) and attr == "size": return x.size() else: - return getattr(value, attr) + return getattr(x, attr) def indexable(x, code=None): -- GitLab