From 4a4a0369a9261ac6ce93db7fec098d1e6be4e196 Mon Sep 17 00:00:00 2001 From: Aurelius84 Date: Fri, 15 Jul 2022 21:34:42 +0800 Subject: [PATCH] [Eager]Fix assert statement (#43492) --- python/paddle/tensor/manipulation.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/python/paddle/tensor/manipulation.py b/python/paddle/tensor/manipulation.py index 8d2bfa2a2cb..6c4b1cd22b0 100755 --- a/python/paddle/tensor/manipulation.py +++ b/python/paddle/tensor/manipulation.py @@ -2853,8 +2853,7 @@ def tile(x, repeat_times, name=None): """ if in_dygraph_mode(): if isinstance(repeat_times, core.eager.Tensor): - assert (repeat_times.ndim == 1, - "Only support ndim == 1 while repeat_times is a Tensor.") + assert repeat_times.ndim == 1, "Only support ndim == 1 while repeat_times is a Tensor." repeat_times = repeat_times.numpy().tolist() return _C_ops.final_state_tile(x, repeat_times) -- GitLab