diff options
| author | Matti Picus <matti.picus@gmail.com> | 2023-02-12 09:12:36 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-02-12 09:12:36 +0200 |
| commit | 5c7fde654c7cc9d9f32f29f82f5cb034c3c3ccaa (patch) | |
| tree | 9d21c3e3f62276dbd35303d49203ca4834ee1e09 /numpy/lib/function_base.py | |
| parent | 9dde0a930aa568bbdd3ba176b12d1d46c72d3d4e (diff) | |
| parent | 9d5eafe596e75e30a85c01ed62bb5bea9389adc8 (diff) | |
| download | numpy-5c7fde654c7cc9d9f32f29f82f5cb034c3c3ccaa.tar.gz | |
Merge pull request #23089 from seberg/numpy2-flag
API: Add environment variable for behavior planned in a 2.0
Diffstat (limited to 'numpy/lib/function_base.py')
| -rw-r--r-- | numpy/lib/function_base.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/numpy/lib/function_base.py b/numpy/lib/function_base.py index 0ca3c21c1..f5af314b5 100644 --- a/numpy/lib/function_base.py +++ b/numpy/lib/function_base.py @@ -1311,6 +1311,8 @@ def gradient(f, *varargs, axis=None, edge_order=1): if len_axes == 1: return outvals[0] + elif np._using_numpy2_behavior(): + return tuple(outvals) else: return outvals |
