From deb8a167cdcde0609ef6f611a8e02b50c4a877cd Mon Sep 17 00:00:00 2001 From: Anton Gladky Date: Tue, 12 Oct 2021 09:21:32 +0100 Subject: [PATCH] Fix python numpy warning Last-Update: 2020-11-09 Gbp-Pq: Name 70_fix_python_numpy_warning.patch --- Wrapping/Python/vtkmodules/numpy_interface/algorithms.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Wrapping/Python/vtkmodules/numpy_interface/algorithms.py b/Wrapping/Python/vtkmodules/numpy_interface/algorithms.py index 51e2ea7d..2a5e888f 100644 --- a/Wrapping/Python/vtkmodules/numpy_interface/algorithms.py +++ b/Wrapping/Python/vtkmodules/numpy_interface/algorithms.py @@ -206,7 +206,7 @@ def _global_func(impl, array, axis, controller): return dsa.NoneArray; if res is dsa.NoneArray: - if max_dims is 1: + if max_dims == 1: # Weird trick to make the array look like a scalar max_dims = () res = numpy.empty(max_dims) -- 2.30.2