From 07029e0ced650f6fa37c5b38afad8aa237df9d60 Mon Sep 17 00:00:00 2001 From: wuhuanzhou Date: Mon, 16 May 2022 10:12:43 +0800 Subject: [PATCH] fix sample code error of paddle.lerp, test=document_fix (#42753) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修复paddle.lerp中示例代码错误。 --- python/paddle/tensor/math.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/paddle/tensor/math.py b/python/paddle/tensor/math.py index efd1746f91..98167ebc35 100644 --- a/python/paddle/tensor/math.py +++ b/python/paddle/tensor/math.py @@ -3561,7 +3561,7 @@ def lerp(x, y, weight, name=None): x = paddle.arange(1., 5., dtype='float32') y = paddle.empty([4], dtype='float32') y.fill_(10.) - out = paddle.lerp(start, end, 0.5) + out = paddle.lerp(x, y, 0.5) # out: [5.5., 6., 6.5, 7.] """ -- GitLab