summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Revert "MAINT: `f2py` cleanup (#22885)"revert-22885-cleanCrackfortranRalf Gommers2023-01-223-19/+21
| | | | This reverts commit 6b5cd92675139511b4b24ddfe822e96b03700edb.
* DOC: fail the CI build and do not deploy if docs are not created (#23065)Matti Picus2023-01-222-4/+17
| | | | Adds protection against deploying empty docs when sphinx build fails in circleCI.
* Merge pull request #23064 from seberg/nose-removal-doc-fixupMatti Picus2023-01-222-8/+0
|\ | | | | DOC: Fixup docs after the code removal
| * DOC: Fixup docs after the code removalSebastian Berg2023-01-222-8/+0
|/ | | | | | | CircleCI is currently not set up to fail when docs fail, so this slipped through the cracks. It may be that the testing docs should get a bit more changes then just removing these things.
* Merge pull request #23060 from charris/remove-testing-utils-shimSebastian Berg2023-01-223-30/+5
|\ | | | | DEP: Remove the deprecated ``utils.py`` shim.
| * DEP: Remove the deprecated utils.py shim.Charles Harris2023-01-213-30/+5
|/ | | | | The shim has been deprecated since 2019, the proper place to import utils funtions is directly from numpy.testing.
* Merge pull request #20970 from seberg/reduce-identity-array-methMatti Picus2023-01-2113-129/+508
|\ | | | | ENH: Move identity to the ArrayMethod to allow customization
| * MAINT: Rename `initial` to `legacy_initial` in ArrayMethodSebastian Berg2023-01-202-3/+5
| | | | | | | | | | It should only be used by the legacy method, so also reflect that in the field name.
| * DOC: Adept code comments for clarity based on code reviewSebastian Berg2023-01-204-13/+20
| | | | | | | | Co-authored-by: Matti Picus <matti.picus@gmail.com>
| * MAINT: Prepend scaled float test statics with `sfloat_`Sebastian Berg2023-01-201-14/+14
| | | | | | | | As requested by Matti in review.
| * MAINT: Address review comments by NathanSebastian Berg2023-01-203-23/+24
| |
| * MAINT: Rename PyUFunc_GetIDentity to PyUFunc_GetDefaultIdentitySebastian Berg2023-01-203-5/+6
| |
| * TST: Add test for wrapped ufuncs and reductions via ScaledFloatSebastian Berg2023-01-202-3/+104
| |
| * MAINT: Address many of Marten's commentsSebastian Berg2023-01-206-20/+39
| |
| * MAINT: Remove unneeded labelSebastian Berg2023-01-201-1/+0
| |
| * TST: Fix lint and ensure we have tests for empty arrays and reduceSebastian Berg2023-01-201-1/+14
| |
| * API: Bumpy experimental dtype api versionSebastian Berg2023-01-203-3/+3
| | | | | | | | | | Its a new version (it changed ;)), plus I took the liberty to move things around a bit ABI wise.
| * BUG: Fixup copying the wrong size in the cached path mostlySebastian Berg2023-01-202-8/+8
| |
| * MAINT: Rework things to make reorderability static and default to no initial ↵Sebastian Berg2023-01-207-185/+218
| | | | | | | | value
| * MAINT: Fixup names, and add workaround lost in rebaseSebastian Berg2023-01-201-6/+21
| |
| * MAINT: Rename arraymethod reduction identity getterSebastian Berg2023-01-205-57/+69
| | | | | | | | | | Need to look into whether to cut out the dynamic discovery of reorderability though.
| * DOC,MAINT: Address "simple" review comments by MartenSebastian Berg2023-01-204-27/+32
| |
| * BUG: Fixup the default array-method, got the refcounting wrong...Sebastian Berg2023-01-201-5/+7
| |
| * ENH: Support identity-function in experimental DType APISebastian Berg2023-01-203-0/+66
| | | | | | | | | | Also add it to the wrapped array-method (ufunc) implementation so that a Unit dtype can reasonably use an identity for reductions.
| * ENH: Move identity to the ArrayMethod to allow customizationSebastian Berg2023-01-206-92/+195
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also fixes/changes that the identity value is defined by the reduce dtype and not by the result dtype. That does not make a different in any sane use-case, but there is a theoretical change: arr = np.array([]) out = np.array(None) # object array np.add.reduce(arr, out=out, dtype=np.float64) Where the output result was previously an integer 0, due to the output being of `object` dtype, but now it is the correct float due to the _operation_ being done in `float64`, so that the output should be `np.zeros((), dtype=np.float64).astype(object)`.
* | CI: musllinux_x86_64 (#22864)Andrew Nelson2023-01-205-8/+126
|/ | | [ci skip]
* Merge pull request #23034 from seberg/wrap-trapzRalf Gommers2023-01-202-0/+40
|\ | | | | API: Allow SciPy to get away with assuming `trapz` is a Python function
| * API: Allow SciPy to get away with assuming `trapz` is a Python functionSebastian Berg2023-01-202-0/+40
| | | | | | | | | | | | | | | | | | This wraps `trapz` into a proper python function and then copies all attributes expected on a Python function over from the "fake" version to the real one. This allows SciPy to pretend `trapz` is a Python function to create their own version.
* | Merge pull request #23054 from seberg/pyinstaller-import-fixupCharles Harris2023-01-202-4/+4
|\ \ | |/ |/| MAINT: Move unused import into hook for pyinstaller
| * MAINT: Move unused import into hook for pyinstallerSebastian Berg2023-01-202-4/+4
|/ | | | | | | | | pyinstaller should pack it to allow running the tests, but doesn't pack the tests themselves and thus doesn't find the `import` statements that use `numpy.core._multiarray_tests`. This makes sure that pyinstaller will ship `numpy.core._multiarray_tests` in any case.
* Merge pull request #23041 from charris/remove-nose-testingMatti Picus2023-01-2016-2062/+36
|\ | | | | MAINT: Remove all nose testing support.
| * MAINT: Remove all nose testing support.Charles Harris2023-01-1916-2062/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | NumPy switched to using pytest in 2018 and nose has been unmaintained for many years. We have kept NumPy's nose support to avoid breaking downstream projects who might have been using it and not yet switched to pytest or some other testing framework. With the arrival of Python 3.12, unpatched nose will raise an error. It it time to move on. Decorators removed - raises - slow - setastest - skipif - knownfailif - deprecated - parametrize - _needs_refcount These are not to be confused with pytest versions with similar names, e.g., pytest.mark.slow, pytest.mark.skipif, pytest.mark.parametrize. Functions removed - Tester - import_nose - run_module_suite
* | Merge pull request #23047 from ngoldbaum/custom-dtype-nameSebastian Berg2023-01-202-1/+8
|\ \ | | | | | | MAINT: dtype.name works for NEP 42 dtypes
| * | MAINT: dtype.name works for NEP 42 dtypesNathan Goldbaum2023-01-192-1/+8
|/ /
* | DEP: deprecate np.finfo(None) (#23011)Daiki Shintani2023-01-193-0/+16
| | | | | | | | | | Deprecate np.finfo(None), it may be that we should more generally deprecate `np.dtype(None)` but this is a start and particularly weird maybe. Closes gh-14684
* | Merge pull request #23039 from seberg/fixup-array-func-CMatti Picus2023-01-192-1/+49
|\ \ | | | | | | BUG: Implement `ArrayFunctionDispatcher.__get__`
| * | BUG: Impelement `ArrayFunctionDispatcher.__get__`Sebastian Berg2023-01-182-1/+49
| |/ | | | | | | | | | | | | | | | | | | | | While functions should not normally need this, Python functions do provide it (C functions do not, but we are a fatter object anyway). By implementing `__get__` we also ensure that `inspect.isroutine()` passes. And by that we ensure that Sphinx considers these a `py:function:` role. Closes gh-23032
* | Merge pull request #23038 from seberg/fixup-doc-genMatti Picus2023-01-191-0/+7
|\ \ | | | | | | DOC: Ignore attribute FutureWarning in doc build
| * | DOC: Ignore attribute FutureWarning in doc buildSebastian Berg2023-01-181-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | The docs somehow seem to access `numpy.str`, etc. during the autodoc generation probably. This adds a specific warning filter to hide it. Closes gh-22987
* | | BUG: fix ma.diff not preserving mask when using append/prepend (#22776)Marko Pacak2023-01-194-7/+182
| |/ |/| | | | | | | Port CORE diff relevant code to MA and adapt docstrings examples and add tsts. Closes gh-22465
* | BLD: Build PyPy 3.9 wheels. (#23023)Charles Harris2023-01-181-4/+1
|/ | | | | | NumPy is dropping Python 3.8 for the 1.25.x release cycle. This updates PyPy to 3.9 in order to be consistant with that. Co-authored-by: Matti Picus <matti.picus@gmail.com>
* Merge pull request #23019 from seberg/finalize-non-sequence-stackCharles Harris2023-01-175-31/+30
|\ | | | | DEP: Finalize the non-sequence stacking deprecation
| * DEP: Finalize the non-sequence stacking deprecationSebastian Berg2023-01-175-31/+30
| | | | | | | | | | | | | | | | | | The `__array_function__` API currently will exhaust iterators so we cannot accept sequences reasonably. Checking for `__getitem__` is presumably enough to reject that (and was what the deprecation used). Future changes could allow this again, although it is not a useful API anyway, since we have to materialize the iterable in any case.
* | Merge pull request #22997 from seberg/issue-19291Charles Harris2023-01-173-97/+102
|\ \ | | | | | | API: Fix cython exception handling for exported extern C functions
| * | DOC: Add release note for cython exception fixesSebastian Berg2023-01-121-0/+5
| | |
| * | API: Add "except *" in cython `.pyd` where necessary based on reviewSebastian Berg2023-01-112-10/+10
| | | | | | | | | | | | | | | | | | The incref/decref function shouldn't be able to fail (especially the decref). But right now they can, this will be fixed when we redo clearing (see gh-22924)
| * | API: Fix cython exception handling for exported extern C functionsSebastian Berg2023-01-112-87/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This hopefully fixes them for all the functions currently in the `.pyd` files. A surprising amount of them look like scary thing I wouldn't mind to just delete :). Anyway, had looked at some Cython code today and remembered this. Closes gh-19291
* | | Merge pull request #23020 from seberg/faster-array-functionCharles Harris2023-01-1718-391/+554
|\ \ \ | | | | | | | | ENH: Improve array function overhead by using vectorcall
| * | | DOC: Adept internal docs a bit based on reviewSebastian Berg2023-01-171-2/+4
| | | |
| * | | TST: Cover some more internal array-function code pathsSebastian Berg2023-01-171-0/+50
| | | |