summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* DOC: correct kind for numericaltype code docCenny Wenner2018-06-091-2/+2
| | | | | | Code documentation of numpy scalar types indicated the wrong type (number) for the kind 'i'. This edit moves the indication to the right type (unsignedinteger).
* Merge pull request #11222 from hmaarrfk/documentation_nditerCharles Harris2018-06-091-19/+19
|\ | | | | DOC: Make reference doc nditer examples python3 friendly
| * Updated with correct endMark Harfouche2018-06-021-19/+19
| |
| * Reference doc to nditer is python3 friendlyMark Harfouche2018-06-011-19/+19
| |
* | Merge pull request #11287 from numpy/pr/11063Charles Harris2018-06-081-4/+4
|\ \ | | | | | | DOC: Minor documentation improvements
| * | STY: Revert line unwrapEric Wieser2018-06-081-1/+2
| | |
| * | minor doc improvementsNikita2018-06-081-5/+4
|/ /
* | Merge pull request #11273 from seberg/sort-valgrind-fixCharles Harris2018-06-082-2/+26
|\ \ | | | | | | BUG: Remove invalid read in searchsorted if needle is empty
| * | MAINT: Extract common variableEric Wieser2018-06-081-6/+6
| | |
| * | BUG: Remove invalid read in searchsorted if needle is emptySebastian Berg2018-06-072-4/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | The tests are a bit ugly, but the cache otherwise hides the errors away during testing. The ternary operation did not work, because complex types do not like assignment of 0. Closes gh-11261
* | | Merge pull request #11277 from eric-wieser/fix-older-ctypes-compatCharles Harris2018-06-083-15/+144
|\ \ \ | | | | | | | | BUG: Work around past and present PEP3118 issues in ctypes
| * | | BUG: Work around bugs in pep3118 ctypes by falling back on ↵Eric Wieser2018-06-083-10/+122
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | np.dtype(type(ctype_obj)) Fixes gh-10528 Fixes gh-10978 Fixes gh-11150 A warning is thrown when ctypes misbehaves, in order to not hide issues that need fixing upstream
| * | | MAINT: Extract helper functionEric Wieser2018-06-081-13/+32
| | | |
| * | | MAINT: Don't steal a referenceEric Wieser2018-06-081-3/+1
| | | |
* | | | DOC: make docstring of np.interp clearer (#11280)Jörg Döpfert2018-06-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * update docstring of interp() * change "calculate" to "evaluate" to be consistent * remove "values" * make "data points" consistent
* | | | Merge pull request #11155 from eric-wieser/datetime-stack-overflowMarten van Kerkwijk2018-06-084-21/+41
|\ \ \ \ | |/ / / |/| | | BUG: Prevent stackoverflow in conversion to datetime types
| * | | MAINT: Use moved definition of Npy_EnterRecursiveCallEric Wieser2018-05-241-11/+2
| | | |
| * | | BUG: Prevent stackoverflow in conversion to datetime typesEric Wieser2018-05-243-10/+39
| | | | | | | | | | | | | | | | Fixes gh-11154
* | | | Merge pull request #11246 from eric-wieser/pyarray_new_with_baseEric Wieser2018-06-0720-431/+298
|\ \ \ \ | | | | | | | | | | BUG: Set ndarray.base before __array_finalize__
| * | | | BUG: Set ndarray.base before calling __array_finalize__Eric Wieser2018-06-0720-312/+194
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #11237 Without this, we expose arrays to python before the lifetime of their buffer has been correctly attached, which can lead to use-after-frees (see the referenced issue). Unfortunately, this means that `PyArray_SetBaseObject(arr, base)` is still broken in downstream code for any cases where `arr.__array_finalize__ is not None`. We may have no choice but to deprecate this function, and expose PyArray_FromDescrAndBase. But lets leave fixing public API to a later date...
| * | | | MAINT/STY: Line wrap PyArray_NewFromDescr consistentlyEric Wieser2018-06-0516-165/+150
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also move an assignment ouf of an if. Only targeting calls that then go on to call PyArray_SetBaseObject
* | | | | Merge pull request #11275 from seberg/tst-no-empty-sortCharles Harris2018-06-071-4/+6
|\ \ \ \ \ | | | | | | | | | | | | TST: Do not use empty arrays in tests (unless they are not read)
| * | | | | TST: Do not use empty arrays in tests (unless they are not read)Sebastian Berg2018-06-081-4/+6
| | |_|/ / | |/| | | | | | | | | | | | | | | | | | Not initializing arrays throws off valgrind, so avoid it here. For a while I thought it was just a false positive due to some SSE string compare function.
* | | | | Merge pull request #10970 from eric-wieser/cut-down-ctypeslibCharles Harris2018-06-073-114/+101
|\ \ \ \ \ | | | | | | | | | | | | WIP: Remove fragile use of __array_interface__ in ctypeslib.as_array
| * | | | | BUG: Remove fragile use of __array_interface__ in ctypeslib.as_arrayEric Wieser2018-05-263-109/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Everything behaves a lot better if we let the array constructor handle it, which will use the ctypes PEP3118 support. Bugs this fixes: * Stale state being attached to pointer objects (fixes gh-2671, closes gh-6214) * Weird failure modes on structured arrays (fixes-10978) * A regression in gh-10882 (fixes gh-10968)
| * | | | | MAINT: Pull repeated decorators up to their containing classEric Wieser2018-04-241-12/+9
| | | | | |
| * | | | | MAINT: Use assert_equalEric Wieser2018-04-241-4/+4
| | | | | |
| * | | | | TST: Add tests for numpy.ctypeslib.as_arraytynn2018-04-241-2/+24
| | | | | |
* | | | | | Merge pull request #11018 from mhvk/gufunc-axis-and-keepdimsCharles Harris2018-06-077-24/+271
|\ \ \ \ \ \ | | | | | | | | | | | | | | ENH: Implement axis for generalized ufuncs.
| * | | | | | TST: Add a new gufunc with (i)->(i) signature for testing with axis.Marten van Kerkwijk2018-06-072-1/+64
| | | | | | |
| * | | | | | DOC: Add release note about __array_ufunc__.Marten van Kerkwijk2018-06-072-1/+4
| | | | | | |
| * | | | | | MAINT: Interpret gufunc axis directly rather than construct axes.Marten van Kerkwijk2018-06-071-56/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Much faster, and much less code duplication than I feared.
| * | | | | | MAINT: let ufunc override reject passing in both axis and axes.Marten van Kerkwijk2018-06-072-2/+11
| | | | | | |
| * | | | | | DOC: Describe new axis argument.Marten van Kerkwijk2018-06-072-3/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Both in the general documentation and in the release notes.
| * | | | | | ENH: add "axis" argument to generalized ufuncs.Marten van Kerkwijk2018-06-073-13/+160
| | |/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | It is only allowed for gufuncs with a single, shared core dimension.
* | | | | | Merge pull request #11122 from mhvk/assert-array-comparison-with-maskedCharles Harris2018-06-073-41/+57
|\ \ \ \ \ \ | | | | | | | | | | | | | | BUG,MAINT: Ensure masked elements can be tested against nan and inf.
| * | | | | | MAINT: clean up assert_array_compare a bit further.Marten van Kerkwijk2018-06-043-10/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This brought to light two bugs in tests, which are fixed here, viz., that a sample ndarray subclass that tested propagation of an added parameter was incomplete, in that in propagating the parameter in __array_wrap__ it assumed it was there on self, but that assumption could be broken when a view of self was taken (as is done by x[~flagged] in the test routine), since there was no __array_finalize__ defined. The other subclass bug counted, incorrectly, on only needing to provide one type of comparison, the __lt__ being explicitly tested. But flags are compared with __eq__ and those flags will have the same subclass.
| * | | | | | BUG,MAINT: Ensure masked elements can be tested against nan and inf.Marten van Kerkwijk2018-05-272-38/+41
| | |_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The removal of nan and inf from arrays that are compared using test routines like assert_array_equal treated the two arrays separately, which for masked arrays meant that some elements would not be removed when they should have been. This PR corrects this.
* | | | | | Merge pull request #10444 from ahaldane/dragon4_otherformats_splitCharles Harris2018-06-077-14/+345
|\ \ \ \ \ \ | | | | | | | | | | | | | | MAINT: Implement float128 dragon4 for IBM double-double (ppc64)
| * | | | | | BUG: Implement float128 dragon4 for IBM double-double (ppc64)Allan Haldane2018-06-067-14/+345
| | |/ / / / | |/| | | |
* | | | | | Merge pull request #11269 from charris/fix-unused-variableMatti Picus2018-06-071-1/+1
|\ \ \ \ \ \ | | | | | | | | | | | | | | BUG: Correct use of NPY_UNUSED.
| * | | | | | BUG: Correct use of NPY_UNUSED.Charles Harris2018-06-071-1/+1
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace `NPY_UNUSED(*param)` by `*NPY_UNUSED(param)`. Closes #11267.
* | | | | | Merge pull request #11263 from charris/update-after-1.14.4Charles Harris2018-06-075-51/+142
|\ \ \ \ \ \ | |/ / / / / |/| | | | | DOC: Update master after NumPy 1.14.4 release.
| * | | | | DOC: Update master after NumPy 1.14.4 release.Charles Harris2018-06-065-51/+142
|/ / / / / | | | | | | | | | | | | | | | [skip ci]
* | | | | Merge pull request #11257 from mhvk/ufunc-parsing-no-borrowed-refsMarten van Kerkwijk2018-06-062-13/+33
|\ \ \ \ \ | |_|_|/ / |/| | | | BUG: ensure extobj and axes have their own references.
| * | | | BUG: ensure extobj and axes have their own references.Marten van Kerkwijk2018-06-062-13/+33
| | | | |
* | | | | Merge pull request #11167 from ahaldane/dragon4_float128_part1Charles Harris2018-06-053-541/+839
|\ \ \ \ \ | | | | | | | | | | | | MAINT: Cleanup dragon4 code in various ways
| * | | | | MAINT: Add comment in dragon4 code.Charles Harris2018-06-051-0/+1
| | | | | | | | | | | | | | | | | | [ci skip]
| * | | | | MAINT: replace static BigInts in dragon4 by dummy managerAllan Haldane2018-06-041-127/+196
| | | | | |
| * | | | | MAINT: Reorganize Dragon4 code to clarify float formatsAllan Haldane2018-06-043-466/+694
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Define the float format macros NPY_*_BINFMT. Reorg formatting functions to refer to specific formats. Make BigInt variables static to avoid using up stack space. Dragon4 now takes a BigInt mantissa, not uint64. Define Dragon4_Options struct to pass options.