From be5768eda78181c3d3966212d26a0e26e7858fca Mon Sep 17 00:00:00 2001 From: Jackson McClintock Date: Thu, 22 Feb 2024 16:33:44 -0500 Subject: [PATCH] fix: minor improvement in `mean` for paddle backend --- ivy/functional/backends/paddle/statistical.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ivy/functional/backends/paddle/statistical.py b/ivy/functional/backends/paddle/statistical.py index 467d7701c326a..fc036b4465474 100644 --- a/ivy/functional/backends/paddle/statistical.py +++ b/ivy/functional/backends/paddle/statistical.py @@ -129,7 +129,7 @@ def mean( if 0 in x.shape: shape = _calculate_reduced_shape(x, axis, keepdims) ret = paddle.empty(shape) - if paddle.is_complex(x): + elif paddle.is_complex(x): ret = paddle.complex( paddle.mean(x.real(), axis=axis, keepdim=keepdims), paddle.mean(x.imag(), axis=axis, keepdim=keepdims),