summaryrefslogtreecommitdiff
path: root/numpy
Commit message (Collapse)AuthorAgeFilesLines
...
* | | BUG: Fixes for numpy.testing.overrides (#22879)Nathan Goldbaum2023-01-022-1/+5
| | | | | | | | | Followup for gh-22533. Adds a missing return statement to get_overridable_numpy_ufuncs (oops!) and imports numpy.testing.overrides into numpy.testing so e.g. tab completion on numpy.testing works for overrides.
* | | Merge pull request #22905 from l-johnston/add_linspace_testMatti Picus2023-01-021-0/+9
|\ \ \ | | | | | | | | TST: Add linspace test case for any_step_zero and not _mult_inplace
| * | | TST: Add linspace test case for any_step_zero and not _mult_inplaceLee Johnston2022-12-301-0/+9
| | | |
* | | | BUG: np.loadtxt cannot load text file with quoted fields separated by ↵dmbelov2023-01-013-1/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | whitespace (#22906) Fix issue with `delimiter=None` and quote character not working properly (not using whitespace delimiter mode). Closes gh-22899
* | | | Merge pull request #22777 from pkubaj/patch-1Sayed Adel2022-12-312-4/+20
|\ \ \ \ | |/ / / |/| | | ENH: Properly support FreeBSD/powerpc64
| * | | ENH: Detect CPU features on FreeBSD/powerpc64*pkubaj2022-12-302-4/+20
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | 1. FreeBSD uses elf_aux_info() instead of getauxval. 2. Switch to using compiler macros for detecting POWER platform FreeBSD sets the machine name (what uname -m prints) on all powerpc* to just powerpc. To identify actual architecture, uname -p should be used, but this is not present in uname() function. Thus, the only way to correctly detect platform is to use what uname prints and also check compiler defines.
* | | DOC: Add blurb about rotation direction to rot90 docstring (#22880)Matthew Muresan2022-12-291-0/+2
| | | | | | | | | | | | | | | | | | | | | * DOC: Add a note to the documentation of the rot90 The note added indicates that rotation is counter clockwise with the default argumemnts. Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
* | | Merge pull request #22891 from ev-br/argmin_tests_repeatSebastian Berg2022-12-271-16/+16
|\ \ \ | |_|/ |/| | TST: tests/core/test_multiarray:TestArg{Min,Max}: stray `np.repeat `
| * | TST: tests/core/test_multiarray:TestArg{Min,Max}Evgeni Burovski2022-12-261-16/+16
| | | | | | | | | | | | | | | | | | | | | The test does `a.repeat(129)` and discards the result: >>> a.repeat(129) >>> np.argmin(a)
* | | BUG: Use whole file for encoding checks with `charset_normalizer` [f2py] ↵Rohit Goswami2022-12-253-25/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#22872) * BUG: Use whole file for encoding checks [f2py] * DOC: Add a code comment Co-authored-by: melissawm <melissawm@gmail.com> * TST: Add a conditional unicode f2py test * MAINT: Add chardet as a test requirement * ENH: Cleanup and switch f2py to charset_normalizer * MAINT: Remove chardet for charset_normalizer * TST: Simplify UTF-8 encoding [f2py] Co-authored-by: melissawm <melissawm@gmail.com>
* | | BUG: Fix integer overflow in in1d for mixed integer dtypes #22877 (#22878)Miles Cranmer2022-12-252-4/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * TST: Mixed integer types for in1d * BUG: Fix mixed dtype overflows for in1d (#22877) * BUG: Type conversion for integer overflow check * MAINT: Fix linting issues in in1d * MAINT: ar1 overflow check only for non-empty array * MAINT: Expand bounds of overflow check * TST: Fix integer overflow in mixed boolean test * TST: Include test for overflow on mixed dtypes * MAINT: Less conservative overflow checks
* | | revert detection for meson.buildmattip2022-12-252-1/+24
| | |
* | | MAINT: restore npymath implementations needed for freebsdmattip2022-12-253-18/+446
| | |
* | | Merge pull request #22861 from ↵Matti Picus2022-12-232-4/+39
|\ \ \ | | | | | | | | | | | | | | | | Developer-Ecosystem-Engineering/convert_non_bool_to_bool BUG, SIMD: Restore behavior converting non bool input to 0x00/0xff
| * | | Update logical_and to avoid extra mask ops in AVX512Developer-Ecosystem-Engineering2022-12-211-16/+28
| | | |
| * | | Add regression test for gh-22845Developer-Ecosystem-Engineering2022-12-211-0/+11
| | | |
| * | | BUG, SIMD: Restore behavior converting non bool input to 0x00/0xffDeveloper-Ecosystem-Engineering2022-12-211-0/+12
| | | | | | | | | | | | | | | | This resolves https://github.com/numpy/numpy/issues/22845 by restoring prior behavior to convert non bool input
* | | | Merge pull request #22869 from seberg/issue-22835Charles Harris2022-12-221-0/+2
|\ \ \ \ | | | | | | | | | | TST: Ignore nan-warnings in randomized nanfunction `out=` tests
| * | | | TST: Ignore nan-warnings in randomized out testsSebastian Berg2022-12-221-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The tests randomize the nan pattern and thus can run into these (additional) warnings, so ignore them. (Could also fix the random seed, but this should do) Closes gh-22835
* | | | | TST: Fixup string cast test to not use `tiny`Sebastian Berg2022-12-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is not much value in these values anyway probably, but tiny isn't reliably for double-double (maybe it should be, but that is a different issue). Fixup for gh-22855 and gh-22868
* | | | | Merge pull request #22851 from seiko2plus/issue_22841Sebastian Berg2022-12-223-26/+57
|\ \ \ \ \ | | | | | | | | | | | | BUG, SIMD: Fix memory overlap in ufunc comparison loops
| * | | | | MAINT: Remove unused umath macros IS_BLOCKABLE_BINARY_BOOL*Sayed Adel2022-12-221-13/+0
| | | | | |
| * | | | | BUG, SIMD: Fix memory overlap on comparison accumulateSayed Adel2022-12-212-13/+57
| |/ / / /
* | | | | Merge pull request #22853 from mattip/issuesCharles Harris2022-12-211-31/+9
|\ \ \ \ \ | | | | | | | | | | | | MAINT: enhance show_runtime
| * | | | | MAINT: expand show_rutime, add it to issue template [skip ci]mattip2022-12-211-31/+9
| |/ / / /
* | | | | Merge pull request #22855 from seberg/issue-22843Charles Harris2022-12-213-4/+24
|\ \ \ \ \ | |_|/ / / |/| | | | BUG: Fortify string casts against floating point warnings
| * | | | BUG: Fortify string casts against floating point warningsSebastian Berg2022-12-213-4/+24
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes the check for floating point warnings, which is enough in practice. (In principle ufuncs or structured dtypes can chain casts in a way that causes us to check anyway.) It also checks for isfinite in the scalar repr code so the warnings shouldn't be set to begin with. Closes gh-22843
* | | | Merge pull request #22849 from seberg/issue-22720Charles Harris2022-12-212-1/+18
|\ \ \ \ | | | | | | | | | | API: Ensure a full mask is returned for masked_invalid
| * | | | API: Ensure a full mask is returned for masked_invalidSebastian Berg2022-12-212-1/+18
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Matplotlib relies on this, so we don't seem to have much of a choice. I am surprised that we were not notified of the issue before release time. Closes gh-22720, gh-22720
* | | | BLD: Help raspian arm + clang 13 about `__builtin_mul_overflow`Sebastian Berg2022-12-212-3/+6
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | It seems on raspian arm with clang 13 `__builtin_mul_overflow` is defined for `int` but doesn't work for `ptrdiff_t` (and maybe others). This checks for `ptrdiff_t` instead of int, which was reported to work-around the issue. Closes gh-22811
* | | Merge pull request #22846 from seiko2plus/issue_22841Charles Harris2022-12-202-9/+9
|\ \ \ | | | | | | | | BUG, SIMD: Fix the bitmask of the boolean comparison
| * | | BUG, SIMD: Fix the bitmask of the boolean comparisonSayed Adel2022-12-212-9/+9
| |/ /
* | | BUG: Do not use getdata() in np.ma.masked_invalidSebastian Berg2022-12-192-5/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the minimal solution to fix gh-22826 with as little change as possible. We should fix `getdata()` but I don't want to do that in a bug-fix release really. IMO the alternative is to revert gh-22046 which would also revert the behavior noticed in gh-22720 (which seems less harmful though). Closes gh-22826
* | | Merge pull request #22828 from bnavigator/ignore-distutils-apiCharles Harris2022-12-191-0/+2
|\ \ \ | | | | | | | | TST: ignore more np.distutils.log imports
| * | | TST: ignore more np.distutils.log importsBen Greiner2022-12-191-0/+2
| |/ / | | | | | | | | | | | | | | | Ignore two more modules from np.distutils.log found by test_public_api.py::test_all_modules_are_expected_2 Closes #22827
* | | BUG: Ensure correct behavior for rows ending in delimiter in loadtxt (#22836)Sebastian Berg2022-12-193-3/+18
|/ / | | | | | | | | | | | | If a row ends in a delimiter, `add_fields` can be called twice without any field actually being parsed. This causes issues with the field buffer setup. closes gh-22833
* | Merge pull request #22771 from seiko2plus/issue_22461Sebastian Berg2022-12-1816-177/+405
|\ \ | | | | | | BUG, SIMD: Fix invalid value encountered in several ufuncs
| * | ENH, SIMD: Discard non-signaling comparison intrinsicsSayed Adel2022-12-1514-173/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Providing non-signaling comparison intrinsics that guarantee no FP invalid exception in case of qNaN sounds great but it cost unacceptable extra intrinsics on ppc64le(VSX) and x86(SSE). Therefore, an integer definition #NPY_SIMD_CMPSIGNAL has been provided instead to differenate between SIMD extensions that support only supports signaling comparison.
| * | BUG, SIMD: Fix invalid value encountered in rint/trunc/ceil/floor on armhf/neonSayed Adel2022-12-142-68/+91
| | |
| * | BUG, SIMD: Fix invalid value encountered in rint/trunc/ceil/floor on x86/SSE2Sayed Adel2022-12-142-50/+135
| | |
| * | BUG, SIMD: Fix invalid value encountered in expm1 when SVML/AVX512 enabledSayed Adel2022-12-141-0/+10
| | |
| * | ENH, TST: Test all FP unary ufunc against any unexpected fp exceptionsSayed Adel2022-12-142-11/+80
| | |
| * | BUG, SIMD: Fix invalid value encountered in cos/sin on aarch64 & ppc64leSayed Adel2022-12-142-2/+2
| | |
| * | ENH, SIMD: Add ordered comparison intrinsics guarantees non-signalingSayed Adel2022-12-149-47/+239
| | |
* | | REV: revert change to `numpyconfig.h` for sizeof(type) hardcoding on macOSRalf Gommers2022-12-151-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reverts gh-22614, and adds more detail about why that code is needed and when it can be removed. Closes gh-22796 [skip cirrus] [skip circle]
* | | Merge pull request #22784 from eerovaher/percentile-plot-legendSebastian Berg2022-12-151-1/+2
|\ \ \ | | | | | | | | DOC: Fix legend placement in `numpy.percentile()` docs
| * | | DOC: Fix legend placement in `percentile` docsEero Vaher2022-12-121-1/+2
| | |/ | |/| | | | | | | | | | | | | | | | A plot is meant to demonstrate the different methods of estimating the percentile that `numpy.percentile()` supports, but previously the legend covered a large fraction of it. Now the legend is drawn next to the plot.
* | | MAINT: remove unused API documentation generationmattip2022-12-155-50/+6
| | |
* | | Merge pull request #22167 from ↵Matti Picus2022-12-157-337/+425
|\ \ \ | | | | | | | | | | | | | | | | Developer-Ecosystem-Engineering/add_simd_bool_logical_andornot_absolute ENH: Add SIMD versions of bool logical_&&,||,! and absolute
| * | | ENG, SIMD: Dispatch bool (invert, add, fmax, fmin...)Sayed Adel2022-12-082-34/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Following functions are defined by umath generator to enable runtime dispatching without the need to redefine them within dsipatch-able sources: BOOL_invert, BOOL_add, BOOL_bitwise_and BOOL_bitwise_or, BOOL_logical_xor BOOL_bitwise_xor, BOOL_multiply BOOL_maximum, BOOL_minimum, BOOL_fmax, BOOL_fmin