| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Fixes the incompatible type comparison found in #17490.
This also corrects the logic to not print the heading when only private/magic methods are present.
|
|\
| |
| | |
BUG: Indentation for docstrings
|
| | |
|
|/
|
|
|
|
| |
Using inspect.signature instead of `np.compat.getargspec` solves this problem.
`inspect.signature` also handles stripping the `self` argument of methods for us.
|
|
|
|
|
|
|
| |
`global` is only needed if a variable appears on the left of an assignment.
These variables do not.
Most suffer from the misconception that `var[x] = y` requires `var` to be global, but it does not.
|
|
|
| |
More sys.version cleanup.
|
| |
|
|
|
|
|
|
|
| |
Inheriting from object was necessary for Python 2 compatibility to use
new-style classes. In Python 3, this is unnecessary as there are no
old-style classes.
Dropping the object is more idiomatic Python.
|
|
|
|
|
| |
As numpy is Python 3 only, these import statements are now unnecessary
and don't alter runtime behavior.
|
| |
|
|
|
|
| |
* Deprecate class SafeEval
|
| |
|
| |
|
| |
|
|
|
|
| |
Closes #8058.
|
| |
|
|
|
|
|
|
|
|
|
| |
* added lib.recfunctions to refguide
PUBLIC_SUBMODULES, as the doctests
were otherwise not getting executed
* fixed a failing doctest in
recfunctions after above activation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* restored regression comment in
numpy/core/defchararray.py
* fixed the dimensionality of the z
array in all() docstring in
numpy/core/fromnumeric.py; this isn't
detected because it is in-line with
variable memory addresses which are
tagged as variable for refguide
* byte_bounds() docstring adjusted
to reflect non-variable dtype
after reviewer requested removal
of complex dtype
* restore an original comment
in matmul docstring, as requested
by reviewer
|
| |
|
|
|
|
|
|
|
|
| |
* ported the refguide_check module from SciPy for usage
in NumPy docstring execution/ verification; added the
refguide_check run to Azure Mac OS CI
* adjusted NumPy docstrings such that refguide_check passes
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes GH-12271
Tests verify that everything in ``dir(numpy)`` either has ``__module__`` set to
``'numpy'``, or appears in an explicit whitelist of undocumented functions and
exported bulitins. These should eventually be documented or removed.
I also identified a handful of functions for which I had accidentally not setup
dispatch for with ``__array_function__`` before, because they were listed under
"ndarray methods" in ``_add_newdocs.py``. I guess that should be a lesson in
trusting code comments :).
|
| |
|
| |
|
|
|
| |
Found via `codespell`
|
|
|
|
|
| |
Also add a hint to the documentation advising the use of moveaxis over rollaxis.
Tests for rollaxis are left alone.
|
|
|
|
| |
Bare except is very rarely the right thing
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This requires to base masked median on sort(endwith=False) as we need to
distinguish Inf and NaN.
Using Inf as filler element of the sort does not work as then the mask is not
guaranteed to be at the end.
Closes gh-8340
Also fixed 1d ma.median not handling np.inf correctly, the nd variant
was ok.
|
| |
|
|
|
|
| |
The strings in error messages were left untouched
|
| |
|
| |
|
|
|
|
|
| |
Both of these functions will be removed in Python 3.6 and were deprecated
in 3.5. The numpy versions are not full versions, but hopefully suffice.
|
|\
| |
| | |
BF: do not crash lookfor if inspection fails - catch any Exception
|
| | |
|
|/
|
|
|
|
| |
This is to make it easier to find and remove deprecated features.
It would be a good idea if all deprecations were made with similar
comments.
|
|
|
|
| |
The class is no longer used in numpy and was never exported.
|
|
|
|
|
| |
This does what is needed now that the compiler module is no longer
used.
|
|
|
|
|
|
| |
The ast module was added in Python 2.6 as a replacement for the compiler
module. As we no longer support Python versions < 2.6, all uses of the
compiler module can be removed.
|
|
|
|
| |
The rules enforced are the same as those used for scipy.
|
|
|
|
|
|
| |
Some of those problems look like potential coding errors. In those
cases a Fixme comment was made and the offending code, usually an
unused variable, was commented out.
|
| |
|
|
|
|
| |
close gh-4345
|
|
|
|
| |
Fixes gh-2561
|
|
|
|
|
|
| |
The numarray info function is called by lib.utils.info. Rename it
to _info and copy into lib/utils.py. Some modifications are made
as it only needs to support numpy.
|
| |
|
|
|
|
|
|
|
| |
Run the 2to3 ws_comma fixer on *.py files. Some lines are now too long
and will need to be broken at some point. OTOH, some lines were already
too long and need to be broken at some point. Now seems as good a time
as any to do this with open PRs at a minimum.
|
|
|
|
|
|
|
|
|
|
|
|
| |
WarningManager was a workaround for the lack of the with statement
in Python versions < 2.6. As those versions are no longer supported
it can be removed.
Deprecation notes are added to WarningManager and WarningMessage, but
to avoid a cascade of messages in third party apps, no warnings are
raised at this time, that can be done later.
Closes #3519.
|
| |
|