| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|\
| |
| | |
MAINT: Fix typos in random.hypergeometric's notes
|
| | |
|
|/ |
|
|\
| |
| | |
MAINT: Remove duplicate docstring and incorrect location of __all__ from np.random
|
| |
| |
| |
| |
| |
| | |
np.random
This should fix a lot of LGTM errors
|
|/
|
|
| |
Spotted by keithbriggs - see: gh-11728.
|
|
|
| |
The transform in line 620 onwards was the polar method, not Box-Muller. See section 11.3.1 of "Introduction to probability models" by Sheldon Ross (https://fac.ksu.edu.sa/sites/default/files/introduction-to-probability-model-s.ross-math-cs.blog_.ir_.pdf).
|
|
|
|
|
|
|
|
| |
unnecessary import dependencies
pytesttester is used by every single subpackage, so making it depend on np.testing just creates cyclic dependencies that can lead to circular imports
Relates to #11457
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
Use fancy indexing instead of a shuffle to avoid unnecessary
object access
closes #11013
|
| |
|
|\
| |
| | |
DOC: rework documents and silence warnings during sphinx build
|
| | |
|
|\ \
| | |
| | | |
DOC: Fix link in `See Also` section of `randn` docstring.
|
| |/ |
|
|/
|
|
|
|
| |
* fixes #10886 : Bad link to `np.random.randint`
* Issue #10886: Change from `np.random.randint` to `randint` in 'See Also` doc-string section of mtrand.pyx
|
|
|
|
|
| |
That function is nose specific and has not worked since `__init__` files
were added to the tests directories.
|
|
|
|
|
|
|
|
| |
Numpy can now be tested using the standard
`python -c"import numpy; numpy.test()"`
construct.
|
|
|
|
|
| |
The "bench" testing with the old bench files is no longer supported.
These days we use `runtests.py` and `asv`.
|
|
|
|
|
|
|
|
| |
* [BUG] add "symmetric" to "positive-semidefinite"
* Break line, fix comments
* break long line
|
|
|
| |
Found via `codespell`
|
|
|
| |
Found via `codespell`
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
WRITEBACKIFCOPY (#9639)
* ENH: add API to resolve UPDATEONCOPY outside dealloc, test and use
* BUG: Fix usage of keyword "from" as argument name for "can_cast".
Also removed inconsistency between the second argument name
between documentation ("totype") and code ("to").
* UPDATEIFCOPY -> WRITEBACKIFCOPY, documentation
* fixes for review
* review2, fix new test
* fix new test for using self.assert_deprecated
* change deprecation logic as per review
* new logic exposed places where PyArray_ResolveWritebackIfCopy not called
* deprecate PyArray_XDECREF_ERR in favor of PyArray_DiscardWritebackIfCopy
* code review changes
* clean up merge cruft
* fix from review
* fixes from review
* extend the release note
|
|
|
|
|
|
|
| |
Prevent empty arrays or arrays with more than 1 dimension from being
used to seed RandomState
closes #9832
|
|
|
|
| |
Avoids infinite loop.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Current double to long casting in the zipf function depends on
non-standardized behavior when the double is too big to fit in a long.
This is potentially dangerous and makes the code fail with tools such as
AddressSanitizer.
Checks are added here to prevent overflow during casting and make sure
we get the desired behavior.
|
|
|
|
|
|
|
| |
The `import_array()` macro, that defined a C code block that included a
return, was not handled correctly. The fix here is to cdef a replacement
`import_array` function with a defined error return. The new function is
a slight variation of the corresponding function defined by Cython.
|
|
|
|
|
| |
Removes _POSIX_C_SOURCE redefine warnings. Standard library headers
should always be included last.
|
|
|
|
|
|
|
|
| |
Improve description of dtype requirements to correctly indicate float is
supported
Add required range
[skip ci]
|
|
|
|
|
|
|
| |
The `dfnum` parameter is now required to be > 0 rather than
the previous > 1.
[ci skip]
|
|\
| |
| | |
ENH: Remove unnecessary restriction in noncen-f
|
| |
| |
| |
| |
| |
| | |
Set dfnum restriction to be > 0 as required by noncentral chisquare
closes #6638
|
|/
|
|
|
|
| |
Replace direct access wiht Macro
closes #3144
|
|
|
|
|
|
|
|
| |
Dirichlet does not validate inputs and hangs when values are zero.
Adds check that values are strictly positive as required by the
distribution.
closes #2089
|
|
|
|
|
|
|
|
| |
This allows pytest to run with duplicate test file names. Note that
`python <path-to-test-file>` no longer works with this change, nor will
a simple `pytest numpy`, because numpy is imported from the numpy
repository. However, `python runtests.py` and `>>> numpy.test()` are
still available.
|
|
|
|
|
|
|
| |
This is the case for x in {int, bool, str, float, complex, object}.
Using the np.{x} version is deceptive as it suggests that there is a
difference. This change doesn't affect any external behaviour. The
`long` type is missing in python 3, so np.long is still useful
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The aim here is to separate out the nose dependent files prior to adding
pytest support. This could be done by adding new files to the general
numpy/testing directory, but I felt that it was to have the relevant
files separated out as it makes it easier to completely remove nose
dependencies when needed.
Many places were accessing submodules in numpy/testing directly, and in
some cases incorrectly. That presented a backwards compatibility
problem. The solution adapted here is to have "dummy" files whose
contents will depend on whether of not pytest is active. That way the
module looks the same as before from the outside.
In the case of numpy itself, direct accesses have been fixed. Having
proper `__all__` lists in the submodules helped in that.
|
| |
|
| |
|
|\
| |
| | |
DOC: Wrong return type of np.random.choice and wrong variable name in parameter description.
|
| |
| |
| |
| |
| |
| | |
in parameter description.
[ci skip]
|
|/
|
|
|
| |
It's funny because it's fine in EXAMPLE_DOCSTRING.rst.txt that uses the
same example.
|