| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
|
|
|
|
| |
This affected (for example?) if the `dtype=object` was used
without a converter, meaning that the default one is used.
And this is currently the last one, which is `string_` (and thus
bytes).
Closes gh-16189
|
| |
|
|
|
| |
* Run test_large_zip in a child process
|
|
|
| |
* BUG, TST: fix f2py for PyPy, skip one test for PyPy, xfail tests for s390x
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These dtypes do not really make sense as instances. We can (somewhat)
reasonably define np.dtype(np.int64) as the default (machine endianess)
int64. (Arguably, it is unclear that `np.array(arr_of_>f8, dtype="f")`
should return arr_of_<f8, but that would be very noisy!)
However, `np.integer` as equivalent to long, is not well defined.
Similarly, `dtype=Decimal` may be neat to spell `dtype=object` when you
intend to put Decimal objects into the array. But it is misleading,
since there is no special meaning to it at this time.
The biggest issue with it, is that `arr.astype(np.floating)` looks
like it will let float32 or float128 pass, but it will force a
float64 output! Arguably downcasting is a bug in this case.
A related issue is `np.dtype("S")` and especially "S0". The dtype "S"
does make sense for most or all places where `dtype=...` can be
passed. However, it is conceptionally different from other dtypes, since
it will not end up being attached to the array (unlike "S2" which
would be). The dtype "S" really means the type number/DType class
of String, and not a specific dtype instance.
|
| |
|
|
|
|
| |
This implements NEP 34.
|
| |
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
| |
Fix wrong multiplier for /proc/meminfo, and do style cleanups.
|
|\
| |
| | |
DEP: issue deprecation warning when creating ragged array (NEP 34)
|
| | |
|
| | |
|
|/
|
|
| |
Relates to gh-6103
|
|
|
|
|
|
|
|
| |
A BytesWarning can be emitted when bytes are and strings are mismatched.
Catching BytesWarning ensures a better boundary between str and bytes
type. The test suite is now run with the -b flag to emit this warning.
Fixes #9308
|
|\ |
|
| | |
|
| | |
|
| |\ |
|
| | |\
| | | |
| | | | |
DOC: Document/ Deprecate functions exposed in "numpy" namespace
|
| | | | |
|
| | | | |
|
| |/ / |
|
| |\ \
| | | |
| | | | |
BUG: (py2 only) fix unicode support for savetxt fmt string
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
By now, all that is needed is to also allow unicode strings to
pass through. Adds a test for the support which already succeeds
on python3.
Closes gh-4053 (replaces the old PR)
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
a partial mitigation of #12759.
see also https://nvd.nist.gov/vuln/detail/CVE-2019-6446
|
| |/ / |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* minor reviewer adjustments in PR
13301: in test_structured_padded it
is necessary to perform the seek
after writing to the file, and to
specify a fmt option to match
the expected result
|
| |/
| |
| |
| |
| |
| | |
As a general rule, _every_ use of `.descr` is broken.
Fixes #13297
|
|/
|
|
| |
Previously this would fail with `ValueError: could not assign tuple of length 2 to structure with 3 fields.`, now it raises `NotImplementedError`.
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#12448)
* Review F401,F841,F842 flake8 errors (unused variables, imports)
* Review comments
* More tests in test_installed_npymath_ini
* Review comments
|
|
|
|
|
| |
Fixes #10409
Closes #11530
|
|
|
| |
* ENH: Improve support for pathlib.Path objects in more functions
|
|\
| |
| | |
ENH: maximum lines of content to be read from numpy.loadtxt
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* replace most usage of SkipTest() with
pytest.skip()
* where possible, we avoid use of the standard
library SkipTest because unittest skipping
is routed through the pytest nose compatibility
layer in that scenario, which can prevent an easy
trace back to the test line where the skip
occurred
|
|/ |
|
|
|
|
|
|
|
|
| |
After the pytest migration, test classes no longer inherit
from unittest.TestCase and and the fail method does not
exist anymore.
In all these cases, we can use assert_raises and assert_raises_regex instead
|
|
|
|
|
| |
It's a straightforward copy&paste error, but it means not all these
tests get run.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* fixed doc typo
* fixed lib typos
* fixed lapack_lite typos
* Revert "fixed lapack_lite typos"
This reverts commit e7dada860cb73af190234402508ab79965ecd079.
|
|\
| |
| | |
TST: Extract a helper function to test for reference cycles
|
| |
| |
| |
| |
| |
| | |
This also means we can now test that our test is actually able to detect the type of failure we expect
Trying to give myself some tools to debug the failure at https://github.com/numpy/numpy/pull/10882/files#r180813166
|
| |
| |
| |
| | |
Fixes gh-10780
|
|/ |
|
|
|
|
|
| |
That function is nose specific and has not worked since `__init__` files
were added to the tests directories.
|
|
|
|
|
|
|
|
|
|
|
| |
Use standard pytest markers everywhere in the numpy tests. At this point
there should be no nose dependency. However, nose is required to test
the legacy decorators if so desired.
At this point, numpy test cannot be run in the way with runtests, rather
installed numpy can be tested with `pytest --pyargs numpy` as long as
that is not run from the repo. Run it from the tools directory or some
such.
|