summaryrefslogtreecommitdiff
path: root/numpy
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | MAINT: Use the PyArrayScalar_VAL macro where possible (gh-15426)Eric Wieser2020-01-244-37/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we have this macro, we may as well use it. This changes all occurences except the Void ones, since there other fields that don't have accessor macros are also used.
* | | | | | | MAINT: Revert f2py Python 2.6 workaround (gh-15415)Seth Troisi2020-01-232-12/+2
|/ / / / / / | | | | | | | | | | | | Revert ed916ff#diff-c9eccf467e5f6561061d6a5ac4730330 which was needed to workaround http://bugs.python.org/issue4720 which was fixed 12 years ago.
* | | | | | Merge pull request #15407 from charris/replace-basestringSebastian Berg2020-01-2315-46/+36
|\ \ \ \ \ \ | | | | | | | | | | | | | | MAINT: Replace basestring with str.
| * | | | | | MAINT: Replace basestring with str.Charles Harris2020-01-2315-46/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This replaces basestring with str except in - tools/npy_tempita/ - numpy/compat/py3k.py
* | | | | | | Merge pull request #15398 from mwtoews/urllibCharles Harris2020-01-231-15/+5
|\ \ \ \ \ \ \ | |_|/ / / / / |/| | | | | | MAINT: Revise imports from urllib modules
| * | | | | | MAINT: Revise imports from urllib modulesMike Taves2020-01-241-15/+5
| | | | | | |
* | | | | | | Merge pull request #15405 from WarrenWeckesser/undefaCharles Harris2020-01-231-1/+1
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | BUG/TEST: core: Fix an undefined name in a test.
| * | | | | | | BUG/TEST: core: Fix an undefined name in a test.Warren Weckesser2020-01-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This hasn't generated an error because the test is marked `xfail`. Code checkers such as pyflakes will flag it, so fixing it is worthwhile.
* | | | | | | | Merge pull request #15400 from sethtroisi/pytest_cleanupCharles Harris2020-01-231-17/+0
|\ \ \ \ \ \ \ \ | |_|_|/ / / / / |/| | | | | | | MAINT: cleanup _pytesttester.py
| * | | | | | | MAINT: cleanup _pytesttester.pySeth Troisi2020-01-231-17/+0
| |/ / / / / /
* | | | | | | MAINT: Clean up, mostly unused imports.Warren Weckesser2020-01-2332-52/+10
|/ / / / / /
* | | | | | Merge pull request #15393 from eric-wieser/remove-base-handlingMatti Picus2020-01-242-24/+35
|\ \ \ \ \ \ | |/ / / / / |/| | | | | MAINT/BUG: Fixups to scalar base classes
| * | | | | BUG: Do not dispatch to base classes polymorphicallyEric Wieser2020-01-232-17/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previously code was equivalent to something like ```python class SomeScalar(base1, base2): def __new__(cls, *args): return cls.__bases__[1].__new__(*args) ``` This is nonsense and can easily cause recursion, for instance if `cls` is a superclass of SomeScalar. The correct way to spell this is to pin the base class call statically. ```python class SomeScalar(base1, base2): def __new__(cls, *args): return SomeScalar.__bases__[1].__new__(*args) ``` Fixes #15395
| * | | | | MAINT: Remove leftover code which handled integer base classesEric Wieser2020-01-231-15/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This seems to be left from when `np.int_` subclassed `int`, which it no longer does. Change the `if` to an `assert` so that we can catch this type of change in future.
* | | | | | Merge pull request #15362 from mwtoews/def23Matti Picus2020-01-232-38/+11
|\ \ \ \ \ \ | | | | | | | | | | | | | | MAINT: remove internal functions required to handle Python2/3 logic
| * | | | | | MAINT: remove internal functions required to handle Python2/3 logicMike Taves2020-01-222-38/+11
| |/ / / / /
* | | | | | Merge pull request #15366 from mwtoews/F403Matti Picus2020-01-239-14/+19
|\ \ \ \ \ \ | | | | | | | | | | | | | | MAINT: resolve pyflake F403 'from module import *' used
| * | | | | | MAINT: resolve pyflake F403 'from module import *' usedMike Taves2020-01-239-14/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * For external modules, resolve imported members * Most internal relative modules were ignored or marked noqa: F403 * Convert a few internal absolute imports to relative imports
* | | | | | | Merge pull request #15377 from sethtroisi/misc_cleanups2Matti Picus2020-01-233-20/+4
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | MAINT: Cleanup python2 references
| * | | | | | | MAINT: Cleanup python2 referencesSeth Troisi2020-01-213-20/+4
| | | | | | | |
* | | | | | | | Merge pull request #15379 from sethtroisi/misc_cleanups3Matti Picus2020-01-239-45/+18
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | MAINT: Python2 Cleanups
| * | | | | | | | MAINT: Python2 CleanupsSeth Troisi2020-01-219-45/+18
| |/ / / / / / /
* | | | | | | | Merge pull request #15386 from eric-wieser/tidy-scalar-macrosSebastian Berg2020-01-221-14/+14
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | MAINT: clean up some macros in scalarapi.c
| * | | | | | | | MAINT: clean up some macros in scalarapi.cEric Wieser2020-01-221-14/+14
| | |_|/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Using a macro in an if without parens is just weird. Also, simplies macros to use existing macros, and add comments to make clear why `Void` is special.
* | | | | | | | DOC: Updating Chararry Buffer datatypes #15360MLK972020-01-231-1/+1
| | | | | | | |
* | | | | | | | DOC: Updating Chararry Buffer datatypes #15360MLK972020-01-231-1/+1
| |_|/ / / / / |/| | | | | |
* | | | | | | MAINT: Revise imports from collections.abc moduleMike Taves2020-01-226-46/+16
|/ / / / / /
* | | | | | MAINT: Const qualify UFunc inner loops (gh-15355)Kai Striega2020-01-2115-335/+332
| |_|/ / / |/| | | | | | | | | | | | | | | | | | | This PR const qualifies the dimension and strides arguments of PyUFuncGenericFunction. Const qualified arguments make it simpler to reason about the behaviour of these ufuncs and prevents accidental mutation. As the const is now required this PR also const qualifies calls to PyUFuncGenericFunction inside the NumPy source code. This closes #15252
* | | | | Merge pull request #15375 from sethtroisi/misc_cleanupsMatti Picus2020-01-225-78/+59
|\ \ \ \ \ | | | | | | | | | | | | STY: Use `with open` when possible
| * | | | | STY: use `with open` when possibleSeth Troisi2020-01-215-78/+59
| |/ / / /
* | | | | TST: Simplify unicode testSeth Troisi2020-01-211-27/+15
|/ / / /
* | | | Merge pull request #15369 from Kai-Striega/simd_fix_signed_comparisonSebastian Berg2020-01-211-1/+1
|\ \ \ \ | | | | | | | | | | MAINT: simd: Avoid signed comparison warning
| * | | | MAINT: simd: Avoid signed comparison warningkai-striega2020-01-211-1/+1
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We do not need to cast the dimensions (`n`) to ``npy_uintp`` when comparing it to the stride length (of type ``npy_intp``). The cast is kept from similar checks where the cast is required ``(npy_uintp)n < (VECTOR_SIZE_BYTES / sizeof(@type@))`` In this case `strides` is precalcuated as ``VECTOR_SIZE_BYTES / (npy_intp)sizeof(@type@))`` therefore `n` is already of the correct type when the check is performed.
* | | | NEP: issue deprecation warning when creating ragged array (NEP 34)Matti Picus2020-01-2117-57/+135
|/ / / | | | | | | | | | This implements NEP 34.
* | | [MAINT] Cleanup python2 sys.version checksSeth Troisi2020-01-2025-315/+99
| | |
* | | MAINT: Remove unnecessary calls to PyArray_DATA from binomial functionsAlex Henrie2020-01-192-2/+0
| | |
* | | Merge pull request #15279 from mattip/openblasTyler Reddy2020-01-194-7/+15
|\ \ \ | | | | | | | | BUILD: use standard build of OpenBLAS for aarch64, ppc64le, s390x
| * | | MAINT: try to avoid spurious warnings in einsummattip2020-01-171-0/+8
| | | |
| * | | BLD: use 0.3.7 release version, add dependency on libgfortran5mattip2020-01-173-7/+7
| |/ /
* | | Merge pull request #15224 from pv/lapack-lite-symrenameMatti Picus2020-01-2012-37/+787
|\ \ \ | | | | | | | | MAINT: linalg: use symbol suffix in fallback lapack_lite
| * | | GEN: regenerate lapack_litePauli Virtanen2020-01-148-25/+716
| | | |
| * | | MAINT: linalg: use symbol suffix in fallback lapack_litePauli Virtanen2020-01-144-12/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When building the fallback lapack_lite library for numpy.linalg, add symbol suffix to the routines when using 64-bit integer indices. Adjust the lapack_lite generator script to also output a header file that renames the symbols. Moreover, also rename symbols from f2c.c, to be sure (because they have short and generic names that may clash). This avoids a name clash with BLAS/LAPACK names, which can cause problems in corner cases on platforms where inadvertent symbol overriding in dynamic libraries can occur.
* | | | MAINT: Remove unneccessary call to NpyIter_IterationNeedsAPI (#15348)Eric Wieser2020-01-191-2/+0
|\ \ \ \
| * | | | MAINT: Remove unneccessary call to NpyIter_IterationNeedsAPIAlex Henrie2020-01-191-2/+0
| | | | |
* | | | | MAINT: Fix mistype in histogramdd docstringKirill Zinovjev2020-01-191-2/+2
|/ / / /
* | | | ENH: add identity kwarg to frompyfunc (#8255)mattharrigan2020-01-163-8/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ENH: add identity kwarg to frompyfunc * Update umathmodule.c * Add test, docs, and release note for identity Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* | | | Merge pull request #15011 from hmaarrfk/compat_cleanup_35Sebastian Berg2020-01-161-118/+51
|\ \ \ \ | | | | | | | | | | MAINT: cleanup compat.py3k.py
| * | | | MAINT: cleanup compat.py3k.pyMark Harfouche2020-01-031-118/+51
| | | | |
* | | | | Merge pull request #15217 from eric-wieser/deprecate-shape-0Sebastian Berg2020-01-161-6/+29
|\ \ \ \ \ | | | | | | | | | | | | DEP: records: Deprecate treating shape=0 as shape=None
| * | | | | DEP: records: Deprecate treating shape=0 as shape=NoneEric Wieser2020-01-011-6/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `shape=n` is a shorthand for `shape=(n,)` except in the case when `n==0`, when it is a shorthand for `shape=None`. This special case is dangerous, as it makes `fromrecords(..., shape=len(a))` behave surprisingly when a is an empty sequence. Users impacted by this warning either: * Have a bug in their code, and will need to either: - wait for the deprecation to expire - change their code to use `(len(a),)` instead of `len(a)` * Are using the non-preferred spellling, and will need to replace a literal `0` or `False` with `None`