Skip to content

Sync randomgen #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 356 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
356 commits
Select commit Hold shift + click to select a range
9d5adfd
Replace pointer size
bashtage Mar 16, 2018
a9e869c
BLD: Ensure emulated math is used in 32 bit platforms
bashtage Mar 16, 2018
016e182
TST: Add init to test directory
bashtage Mar 17, 2018
ec40947
BLD: Add csv to package data
bashtage Mar 17, 2018
0223c48
BLD: Cache pip
bashtage Mar 17, 2018
43c8746
BLD: Show gcc version
bashtage Mar 17, 2018
292e08f
DOC: Update change-log
bashtage Mar 17, 2018
921c9fe
DOC: Add PyPi badge
bashtage Mar 21, 2018
3d0ad7e
BUG: Restore nogil for fillers
bashtage Mar 21, 2018
dae0ee8
CLN: Remove references to long
bashtage Mar 22, 2018
10e984d
Merge pull request #10 from bashtage/ulonglong
bashtage Mar 22, 2018
61656c4
ENH: Add Box-Muller gauss
bashtage Mar 21, 2018
db709c1
Merge pull request #12 from bashtage/add-box-muller
bashtage Mar 27, 2018
8667564
DOC: Update multithreading doc
bashtage Mar 27, 2018
788bec3
CLN: Remove set/get state for system generator
bashtage Mar 27, 2018
31a8ead
TST: Fix tailing test on 32bit platofrms
bashtage Mar 27, 2018
3d5f1f3
BLD: Add conda recipe
bashtage Mar 27, 2018
27a27ca
ENH: Add integrated legacy generator
bashtage Mar 27, 2018
2557203
Merge pull request #13 from bashtage/legacy-experiments
bashtage Mar 28, 2018
f452fbe
CLN: Remove conda recipe
bashtage Mar 28, 2018
c4ab63e
CLN: Fix str for RandomGenerator
bashtage Mar 28, 2018
3fd4b60
DOC: Update legacy docs
bashtage Mar 28, 2018
dcdf421
BUG: Fix pickle for LegacyGenerator
bashtage Mar 28, 2018
91a6bbc
TST: Make test more verbose
bashtage Mar 28, 2018
532a027
Merge pull request #15 from bashtage/legacy-meta
bashtage Mar 28, 2018
b62875a
CLN: Add absolute_import to avoid noise
bashtage Apr 1, 2018
a4a4165
BUG: Fix absolute_import
bashtage Apr 2, 2018
2330bad
DOC: Spelling changes
bashtage Apr 2, 2018
28f6603
CLN: Remove redeclared type
bashtage Apr 2, 2018
7c53827
BLD: Enable no-sse2 flag
bashtage Apr 3, 2018
657aab0
SYNC/CLN: Sync with upstream changes
bashtage Apr 16, 2018
f3ef206
Merge pull request #16 from bashtage/sync-numpy
bashtage Apr 16, 2018
f878610
BLD: Add lm flag for non-windows platforms
bashtage May 2, 2018
2d6f9d6
Merge pull request #18 from bashtage/add-lm-flag
bashtage May 2, 2018
2d15ae4
typos in URLs
pdebuyl May 22, 2018
1cea186
Merge pull request #19 from pdebuyl/master
bashtage May 22, 2018
d16834c
DOC: Fix doc and example error
bashtage Jun 12, 2018
3bd8ddc
REF: Rename min and max macros
bashtage Jun 14, 2018
c2673f3
Merge pull request #21 from bashtage/rename-min-max-macros
bashtage Jun 14, 2018
ce22f0c
MAINT: Sync with NumPy changes
bashtage Jun 19, 2018
6ade4aa
ENH: Allow empty choice
bashtage Jul 3, 2018
63ababa
Merge pull request #22 from bashtage/sync-upstream
bashtage Jul 3, 2018
f8dc0ae
DOC: Provide a better explanation of bounded int generation
bashtage Sep 22, 2018
963c32e
Merge pull request #27 from bashtage/clarify-rand-int
bashtage Sep 22, 2018
8d9883a
MAINT: Sync with recent upstream changes
bashtage Sep 22, 2018
d1d3d10
DOC: Update docs for 1.15 release [skip ci]
bashtage Sep 22, 2018
f9f1501
Merge pull request #28 from bashtage/sync-upstream
bashtage Sep 22, 2018
44212b7
Merge pull request #1 from bashtage/master
bduvenhage Oct 2, 2018
2e6c2d6
Added an alternative interval generator using Lemire's algorithm. he …
bduvenhage Oct 3, 2018
88fd0f7
Added an alternative interval generator using Lemire's algorithm. he …
bduvenhage Oct 3, 2018
726fdc9
Added a param to RandomGenerator.randint(...) to allow one to choose …
bduvenhage Oct 3, 2018
01ada41
Fix C errors on VS.
bduvenhage Oct 3, 2018
658fae6
Setup travis to run fewer environments while testing.
bduvenhage Oct 3, 2018
450ea5a
Restore travis and appveyor settings.
bduvenhage Oct 3, 2018
5f18b4f
1) Made the parameter order and randint callees consistent. 2) Rename…
bduvenhage Oct 4, 2018
d105c43
DOC: Add license files
bashtage Oct 5, 2018
0613607
MAINT: Remove invalid escape
bashtage Oct 5, 2018
28555bc
Merge pull request #30 from bashtage/add-license
bashtage Oct 5, 2018
70f7c11
REF: Add path using umul
bashtage Oct 5, 2018
2fe3b21
Merge pull request #31 from bashtage/use-umul
bashtage Oct 5, 2018
e21778d
Added Lemire algorithms for generating random numbers within an inter…
bduvenhage Oct 11, 2018
8bd04b4
Comment update. Still need to add cross platform AND architecture alt…
bduvenhage Oct 11, 2018
011f6a2
Some small shuffles and a ToDo comment while testing. bounded_lemire_…
bduvenhage Oct 12, 2018
f346c91
Test non 128bit code.
bduvenhage Oct 17, 2018
04952c9
Test non 128bit code path when 128bit not available.
bduvenhage Oct 17, 2018
9efa940
Added use_masked as param to _bounded tests in benchmark and enabled …
bduvenhage Oct 17, 2018
f3f427d
Added __umulh instrinsic when on _WIN64 architecture.
bduvenhage Oct 18, 2018
ddb6208
Moved condition to use 32-bit generator if range in 32-bit to callee …
bduvenhage Oct 18, 2018
3538ab5
Added and updated some comments.
bduvenhage Oct 18, 2018
3ba347e
Manual fixes to comments and indents.
bduvenhage Oct 18, 2018
d198f07
clang-format with .clang-format file:
bduvenhage Oct 18, 2018
dd6a136
Example of how buffered_uint8 could be abstracted in disributions.c.
bduvenhage Oct 19, 2018
30418cd
Added Lemire rejection sampling for 8 and 16 bit random numbers.
bduvenhage Oct 20, 2018
9d1b60e
Fixed one or two comments and added the unused buffer back to the uin…
bduvenhage Oct 20, 2018
ef49be9
Removed unused 32-bit random buffer.
bduvenhage Oct 21, 2018
531747b
CLN: Add guards to headers
bashtage Oct 21, 2018
bd7127d
Updated benchmark to test Lemire sampling in the worst, typical avera…
bduvenhage Oct 22, 2018
f3b0a2c
Updated the default max bound for benchmark timer_8bit_bounded.
bduvenhage Oct 22, 2018
5aea934
Trigger CI tests.
bduvenhage Oct 22, 2018
5fdedc9
Removed --full benchmark from CI tests.
bduvenhage Oct 22, 2018
87751ff
Trigger CI tests.
bduvenhage Oct 23, 2018
9ca8413
ENH/BUG: Add Xoshiro256starstar generator
bashtage Oct 20, 2018
63143f7
Merge pull request #33 from bashtage/header-guard
bashtage Oct 23, 2018
2f68d87
Merge pull request #32 from bashtage/xoshiro256starstar
bashtage Oct 23, 2018
c41cbef
DOC: Update docs with Xoshiro additions
bashtage Oct 23, 2018
7f17147
Merge pull request #34 from bashtage/update-docs
bashtage Oct 23, 2018
37bea4b
DOC: Update readme
bashtage Oct 24, 2018
2288f2e
Merge branch 'master' into lemire_bounded_random
bduvenhage Oct 24, 2018
803de1f
Merge pull request #2 from bashtage/master
bduvenhage Oct 24, 2018
eacd543
Merge pull request #3 from bduvenhage/master
bduvenhage Oct 24, 2018
2f8ecf6
UPD: Sync with upstream changes
bashtage Nov 5, 2018
5ed4d6d
BLD: Update dependency minimums
bashtage Nov 6, 2018
90af690
Merge pull request #35 from bashtage/sync-recent-numpy-changes
bashtage Nov 6, 2018
d509d33
Merge pull request #29 from bduvenhage/lemire_bounded_random
bashtage Nov 7, 2018
f80e160
RLS: Small clean-up prior to 1.15.1 release
bashtage Nov 10, 2018
6701896
REF: Refactor benchmark
bashtage Nov 11, 2018
e937ebd
Merge pull request #37 from bashtage/benchmark-improve
bashtage Nov 11, 2018
6173d8f
REF: Improve performance testing
bashtage Nov 11, 2018
f879e4f
ENH: Cast covariance to double in random mvnormal
bashtage Dec 14, 2018
7695f19
BUG: Ensure buffer_loc is reset in DSFMT
bashtage Feb 4, 2019
dc6a542
Merge pull request #39 from bashtage/dsfmt-jump-fixes
bashtage Feb 4, 2019
a449164
DOC: Update dirichlet documentation
bashtage Feb 4, 2019
ec81a8e
DOC: Update beta docstring
bashtage Feb 4, 2019
ea65884
BUG: Fix weibull for a=0
bashtage Feb 4, 2019
977b8a3
CLN: Add language_level
bashtage Feb 4, 2019
b42a1b1
BUG: Raise on nan probabilities
bashtage Feb 4, 2019
67ddb4c
CLN: Remove trailing whitespace
bashtage Feb 4, 2019
197da5e
DOC: Fix doc strings
bashtage Feb 4, 2019
7ee40c2
Merge pull request #40 from bashtage/sync-upstream-16.1
bashtage Feb 4, 2019
6887a96
RLS: Release 1.16.0
bashtage Feb 5, 2019
45043e2
Merge pull request #41 from bashtage/rls-1160
bashtage Feb 5, 2019
89293ad
DOC: Fix issue in README.rst
bashtage Feb 5, 2019
3233d69
DOC: Update versions supported
bashtage Feb 5, 2019
e454334
BUG: Protect gamma generation from 0 input
bashtage Feb 18, 2019
cf72d30
TST: Ensure bad value tests are run on new generators
bashtage Feb 18, 2019
fe9cd13
Merge pull request #44 from bashtage/doc-and-other-small-fixes
bashtage Feb 18, 2019
bc0abff
CLN: Match declaration and function
bashtage Feb 18, 2019
e5be493
DOC: Sync upstream doc changes
bashtage Feb 18, 2019
382eba3
BUG: Catch 0.0 shape parameter in float gamme
bashtage Feb 18, 2019
bdc5383
Merge pull request #45 from bashtage/gamma-float-bug
bashtage Feb 19, 2019
5708029
DOC/ENH: Update docstring and enhance logistic
bashtage Feb 19, 2019
7c90d56
CLN/REF: Reorder _legacy to match generator
bashtage Feb 19, 2019
fec6557
Merge pull request #46 from bashtage/final-cleanups
bashtage Feb 19, 2019
5785ca7
ENH: Create boolean and integer ufuncs for isnan, isinf, and isfinite.
qwhelan Feb 26, 2019
175df24
DOC: UPdate docs to reflect upstream changes
bashtage Mar 15, 2019
1511b19
Merge pull request #49 from bashtage/sync-upstream
bashtage Mar 15, 2019
b296b29
DOC: Update README
bashtage Mar 15, 2019
b4256bd
add README-git.md
mattip Mar 20, 2019
9bdb3c7
Merge 'bashtage/randomgen' into randomgen
mattip Mar 20, 2019
f31006a
DOC: fixup actual commands used
mattip Mar 20, 2019
4437112
BUILD: move files out of _randomgen
mattip Mar 20, 2019
e927920
BUILD: first cut at building randomgen
mattip Mar 20, 2019
0adab55
upgrade 'cythonize' and fix absolute imports to relative
mattip Mar 21, 2019
d301712
DOC, BUILD: fail the devdoc build if there are warnings
mattip Mar 21, 2019
601421b
DOC: Attempting to remove duplicate documentation.
bmakos Mar 21, 2019
d079759
MAINT: define NPY_NO_DEPRECATED_API and fix other warnings
mattip Mar 21, 2019
c8cd7b7
Merge pull request #12547 from bashtage/mvnormal-tol-check
ahaldane Mar 21, 2019
0eda21b
Merge pull request #13170 from mattip/doc-warnings-to-error
rgommers Mar 21, 2019
67dbbf7
MAINT: enable pgc64 by always using PCG_EMULATED_MATH
mattip Mar 22, 2019
ca1a509
MAINT: refactor so import randomgen works
mattip Mar 22, 2019
161f69e
MAINT: add TODO comments for pcg64 improvements
mattip Mar 23, 2019
289d804
BENCH: fix Savez suite, previously was actually calling pickle.dump()
qwhelan Mar 23, 2019
a3303a2
MAINT: fix imports, module name in setup.py; remove _testing
mattip Mar 23, 2019
03c664f
Merge pull request #13174 from bmakos/Fix#13013
mattip Mar 24, 2019
6c75254
Merge pull request #13181 from qwhelan/bench_savez
mattip Mar 25, 2019
81f0dda
MAINT: Rewrite numpy.pad without concatenate (gh-11358)
lagru Mar 25, 2019
28bd9a2
MAINT: make cythonize non-recursive, restore examples to proper place
mattip Mar 25, 2019
f65e2d0
MAINT: update to randomgen 7bca296c0b9
mattip Mar 25, 2019
d6dcaed
DOC: correction to numpy.pad docstring (#13149)
grlee77 Mar 25, 2019
170fbbb
ENH: replace mtrand with LegacyGenerator, tweak for compatibility
mattip Mar 25, 2019
b34ed1b
BUG: port f879ef4 to fix GH10839
mattip Mar 26, 2019
4477134
BUG: minimized difference between generator.pyx and _legacy.pyx
mattip Mar 26, 2019
e000e61
DOC: fix namespace in doctests, mark results that are random
mattip Mar 26, 2019
16ba6ea
MAINT: update to randomgen commit 95c8cdd1c
mattip Mar 26, 2019
e6147b9
MAINT: add overlap checks to choose, take, put, putmask (#13182)
ahaldane Mar 27, 2019
39f0dbf
DOC: Use std docstring for multivariate normal (#13203)
bashtage Mar 28, 2019
4397270
BUILD: pin sphinx to before-2.0.0
mattip Mar 28, 2019
fd105d1
Merge pull request #13206 from mattip/pin-sphinx
rgommers Mar 28, 2019
db5fcc8
Merge pull request #12988 from qwhelan/bool_ufunc
eric-wieser Mar 29, 2019
15b14c5
MAINT: Simplify logic in convert_datetime_to_datetimestruct
eric-wieser Mar 26, 2019
27efe4d
TST: add tests for the existence and round-tripping of datetime limits
eric-wieser Mar 26, 2019
303b2d5
MAINT: merge randomgen/fix-legacy
mattip Mar 29, 2019
5128c5a
Adding an example of successful execution of numpy.test() to the Docs
Mar 29, 2019
e74cbc3
TST: always publish Azure tests
tylerjereddy Mar 29, 2019
0adb9be
Merge pull request #13188 from eric-wieser/extract-unit
tylerjereddy Mar 29, 2019
b30b8e2
Merge pull request #13217 from tylerjereddy/azure_tests_always_pub
charris Mar 30, 2019
bea6946
MAINT: cleanup of fast_loop_macros.h
qwhelan Mar 29, 2019
838abd7
MAINT: remove OUTPUT_LOOP_FAST macro and use UNARY_LOOP_FAST instead
qwhelan Mar 29, 2019
4b1d5cb
address comments on #9355
Mar 30, 2019
4685279
ENH: Improve error message for np.repeat
esc Mar 30, 2019
084e32e
Merge pull request #13224 from esc/better_error_for_repeats
mattip Mar 31, 2019
ad885ae
DOC: Fix small issues in mtrand doc strings
bashtage Mar 31, 2019
c93e795
Merge pull request #13216 from vrindaaa/issue-12452
mattip Mar 31, 2019
a8eca5c
Merge pull request #13208 from qwhelan/charris_followup
mattip Mar 31, 2019
ba96ca5
BUG: fix doctests
mattip Mar 30, 2019
51140bd
Merge pull request #13226 from bashtage/mtrand-doc-clean
mattip Mar 31, 2019
f297d31
BUG: Fix of `var` method for complex object arrays
cnighut Apr 1, 2019
a884450
MAINT: Sync with randomgen changes
bashtage Apr 1, 2019
ce5857d
TST: Incorporate edge tests
bashtage Apr 1, 2019
ac66298
MAINT/DOC: Update import locations
bashtage Apr 1, 2019
ee3593d
Merge pull request #2 from bashtage/randomgen-update
mattip Apr 1, 2019
67bcddb
TST: Fix test tolerance
bashtage Apr 1, 2019
783e88f
BUG/MAINT: fix reference count error on invalid input to ndarray.flat…
adeak Apr 2, 2019
e8bd864
DOC: Correctly document the minimum required Sphinx version (#13231)
kritisingh1 Apr 2, 2019
68f2480
DOC: Improve mtrand docstrings
bashtage Apr 2, 2019
2821126
MAINT: replace SETREF with assignment to ret array in ndarray.flat
adeak Apr 2, 2019
bf2feee
MAINT: Remove complex_normal
bashtage Apr 2, 2019
8aeb1e0
Merge pull request #3 from bashtage/randomgen-fixes
mattip Apr 2, 2019
564cffe
BUG: fix docstring tests
mattip Apr 2, 2019
3c977be
Merge pull request #13244 from bashtage/additional-doc-fixes
mattip Apr 2, 2019
173a210
DOC: fix docstring for floor_divide (#13242)
ay11111111111 Apr 2, 2019
8edc438
Merge pull request #13243 from adeak/maint_flat_nosetref_refactor
charris Apr 2, 2019
c06c339
MAINT: Sync with upstream changes
bashtage Apr 2, 2019
c59585e
Merge pull request #4 from bashtage/port-more-changes
mattip Apr 2, 2019
a1c1505
Update release notes
kikocorreoso Apr 2, 2019
96e9b1d
TST: fail Azure CI if test failures
tylerjereddy Apr 2, 2019
9eb9c35
Merge pull request #13253 from tylerjereddy/azure_hard_fail_after_tes…
charris Apr 2, 2019
c1bf6a6
DOC : PyArray_Descr.names undocumented (#13234)
vrindaaa Apr 3, 2019
0a9c313
BUG: fix docstring tests
mattip Apr 2, 2019
b7e01f3
MAINT: move documentation, add to autosummary
mattip Apr 2, 2019
882a542
merge branches
mattip Apr 3, 2019
fc94ef3
DOC: add randomgen docs
mattip Apr 3, 2019
ef2601a
BUILD: re-apply update of numpydoc to latest master
mattip Apr 3, 2019
f486ca2
fix (``code``s) sphinx parse warning
kikocorreoso Apr 3, 2019
e6ab326
BUG: _mtrand => _rand
mattip Apr 4, 2019
c62ee1b
DOC: Small readability improvement
spacescientist Apr 4, 2019
77b2be2
TST: use POWER8 OpenBLAS for CI
tylerjereddy Apr 2, 2019
8fdacfc
MAINT: f2py: Add a cast to avoid a compiler warning.
WarrenWeckesser Apr 5, 2019
8529dfa
Merge pull request #13269 from WarrenWeckesser/fortranobject-warnings
charris Apr 5, 2019
97e3c50
TST: use OpenBLAS for ARMv8 CI
tylerjereddy Apr 5, 2019
91ba86f
ENH: vectorize np.abs for unsigned ints and half, improving performan…
qwhelan Apr 6, 2019
d121225
Merge pull request #13271 from qwhelan/absolute
eric-wieser Apr 6, 2019
0be3fe4
DOC : Correcting bug on Documentation Page (Byteswapping) (#13262)
vrindaaa Apr 6, 2019
306bc58
BUG: Fix null pointer dereference in PyArray_DTypeFromObjectHelper
jwilk Apr 6, 2019
4a33963
Merge pull request #13273 from jwilk-forks/dtypefromobject-nullptr
charris Apr 6, 2019
31f942d
BUG: Correct handling of nans
bashtage Apr 8, 2019
d15ec91
Merge pull request #5 from bashtage/nan-protection-correction
mattip Apr 8, 2019
8b4885c
merge branches
mattip Apr 8, 2019
b6a2f65
Merge 'master' into randomgen
mattip Apr 8, 2019
80a1873
BUG: rework imports for random.mtrand._rand
mattip Apr 8, 2019
d77d18d
DOC: add exclude-members for numpydoc method-as-link handling
mattip Apr 8, 2019
497a00e
Merge pull request #13259 from spacescientist/master
mattip Apr 8, 2019
67b3659
Merge pull request #13264 from tylerjereddy/power8-openblas
mattip Apr 8, 2019
ca8a22c
Merge pull request #13270 from tylerjereddy/armv8-openblas
mattip Apr 8, 2019
b1c743a
add randomgen documentation to the tree
mattip Apr 8, 2019
61c090b
BUG: Correct handling of nans
bashtage Apr 8, 2019
686e9db
TST: Add tests for nan guards
bashtage Apr 8, 2019
c4d6c5d
BUILD: add ipython for documentation example syntax highlighting
mattip Apr 8, 2019
738d03e
merge master
mattip Apr 8, 2019
b728205
Add benchmark for sorting random array.
hameerabbasi Apr 8, 2019
23446e9
DOC: fix docstring
mattip Apr 8, 2019
5c3cb43
Merge pull request #13287 from hameerabbasi/bench-add-sort-random
charris Apr 8, 2019
96cacd7
ENH: use rotated companion matrix to reduce error
mtmoncur Mar 28, 2019
732d52a
ENH: rotate companion matrix for all polynomial bases
mtmoncur Apr 8, 2019
167a31b
Merge pull request #13202 from mtmoncur/rotated-companion-matrix
charris Apr 9, 2019
4006dc3
DOC: update numpydoc to latest master
mattip Apr 9, 2019
29c4b21
Merge pull request #13292 from mattip/numpydoc
rgommers Apr 9, 2019
e7b8ba6
fix test name
Apr 9, 2019
000939a
update tests
Apr 9, 2019
2d80144
BENCH: convert bencmarks to asv format
mattip Apr 9, 2019
d05327b
MAINT: remove files that were part of the origal repo
mattip Apr 9, 2019
d6a8cab
Merge pull request #13219 from kikocorreoso/nan_to_num-enhancement
ahaldane Apr 9, 2019
0b62364
Add benchmark for sorting random array.
hameerabbasi Apr 8, 2019
ad15281
MAINT: fix merge from master
mattip Apr 10, 2019
fab3265
Merge master into randomgen
mattip Apr 10, 2019
a8027f7
DOC: rework randomgen docs to integrate with numpy and fix some links
mattip Apr 10, 2019
95ee88f
ENH: remove convenience functions, require explicit call to gen.brng
mattip Apr 11, 2019
469bf4c
ENH: move code out of numpy.random.randomgen into numpy.random
mattip Apr 11, 2019
bbdf80d
ENH: Extend multinomial
bashtage Apr 11, 2019
732b62a
BUG/ENH: Fix zipf changes missed in NumPy
bashtage Apr 11, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
command: |
python3 -m venv venv
. venv/bin/activate
pip install cython sphinx>=1.8.3 matplotlib
pip install cython sphinx==1.8.5 matplotlib ipython
sudo apt-get update
sudo apt-get install -y graphviz texlive-fonts-recommended texlive-latex-recommended texlive-latex-extra texlive-generic-extra latexmk texlive-xetex

Expand Down
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -167,12 +167,16 @@ numpy/core/src/umath/test_rational.c
numpy/core/src/umath/umath_tests.c
numpy/distutils/__config__.py
numpy/linalg/umath_linalg.c
doc/source/reference/generated
doc/source/**/generated/
benchmarks/results
benchmarks/html
benchmarks/env
benchmarks/numpy
# cythonized files
cythonize.dat
numpy/random/mtrand/mtrand.c
numpy/random/randomgen/*.c
numpy/random/randomgen/legacy/*.c
numpy/random/mtrand/randint_helpers.pxi
numpy/random/randomgen/bounded_integers.pyx
numpy/random/randomgen/bounded_integers.pxd
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ matrix:
env:
# for matrix annotation only
- PPC64_LE=1
# use POWER8 OpenBLAS build, not system ATLAS
- ATLAS=None

before_install:
- ./tools/travis-before-install.sh
Expand Down
5 changes: 5 additions & 0 deletions LICENSE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,8 @@ Name: dragon4
Files: numpy/core/src/multiarray/dragon4.c
License: One of a kind
For license text, see numpy/core/src/multiarray/dragon4.c

Name: randomgen
Files: numpy/random/randomgen and docs/source/random
Licence: NCSA
For license text, see numpy/random/randomgen/LICENSE.md
8 changes: 7 additions & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,11 @@ jobs:
F77=gfortran-5 F90=gfortran-5 \
CFLAGS='-UNDEBUG -std=c99' python3 runtests.py --mode=full -- -rsx --junitxml=junit/test-results.xml"
displayName: 'Run 32-bit Ubuntu Docker Build / Tests'
continueOnError: true
- task: PublishTestResults@2
inputs:
testResultsFiles: '**/test-*.xml'
failTaskOnFailedTests: true
testRunTitle: 'Publish test results for Python 3.6-32 bit full Linux'
- job: macOS
pool:
Expand Down Expand Up @@ -81,7 +83,7 @@ jobs:
displayName: 'install pre-built openblas'
- script: python -m pip install --upgrade pip setuptools wheel
displayName: 'Install tools'
- script: python -m pip install cython nose pytz pytest pickle5 vulture docutils sphinx>=1.8.3 numpydoc matplotlib
- script: python -m pip install cython nose pytz pytest pickle5 vulture docutils sphinx==1.8.5 numpydoc matplotlib
displayName: 'Install dependencies; some are optional to avoid test skips'
- script: /bin/bash -c "! vulture . --min-confidence 100 --exclude doc/,numpy/distutils/ | grep 'unreachable'"
displayName: 'Check for unreachable code paths in Python modules'
Expand All @@ -99,9 +101,11 @@ jobs:
displayName: 'Run Refuide Check'
- script: python runtests.py --mode=full -- -rsx --junitxml=junit/test-results.xml
displayName: 'Run Full NumPy Test Suite'
continueOnError: true
- task: PublishTestResults@2
inputs:
testResultsFiles: '**/test-*.xml'
failTaskOnFailedTests: true
testRunTitle: 'Publish test results for Python 3.6 64-bit full Mac OS'
- job: Windows
pool:
Expand Down Expand Up @@ -200,7 +204,9 @@ jobs:
displayName: 'For gh-12667; Windows DLL resolution'
- script: python runtests.py -n --show-build-log --mode=$(TEST_MODE) -- -rsx --junitxml=junit/test-results.xml
displayName: 'Run NumPy Test Suite'
continueOnError: true
- task: PublishTestResults@2
inputs:
testResultsFiles: '**/test-*.xml'
failTaskOnFailedTests: true
testRunTitle: 'Publish test results for Python $(PYTHON_VERSION) $(BITS)-bit $(TEST_MODE) Windows'
1 change: 1 addition & 0 deletions benchmarks/benchmarks/bench_function_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ class Sort(Benchmark):
['quick', 'merge', 'heap'],
['float64', 'int64', 'uint64'],
[
('random',),
('ordered',),
('reversed',),
('uniform',),
Expand Down
3 changes: 2 additions & 1 deletion benchmarks/benchmarks/bench_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ def setup(self):
self.squares = get_squares()

def time_vb_savez_squares(self):
np.savez('tmp.npz', self.squares)
np.savez('tmp.npz', **self.squares)


class LoadtxtCSVComments(Benchmark):
# benchmarks for np.loadtxt comment handling
Expand Down
99 changes: 99 additions & 0 deletions benchmarks/benchmarks/bench_random.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

import numpy as np

from numpy.random import RandomState
from numpy.random.randomgen import RandomGenerator

class Random(Benchmark):
params = ['normal', 'uniform', 'weibull 1', 'binomial 10 0.5',
Expand Down Expand Up @@ -80,3 +82,100 @@ def time_permutation_2d(self):

def time_permutation_int(self):
np.random.permutation(self.n)

nom_size = 100000

class RNG(Benchmark):
param_names = ['rng']
params = ['DSFMT', 'PCG64', 'PCG32', 'MT19937', 'Xoroshiro128',
'Xorshift1024', 'Xoshiro256StarStar', 'Xoshiro512StarStar',
'Philox', 'ThreeFry', 'ThreeFry32', 'numpy']

def setup(self, brng):
if brng == 'numpy':
self.rg = np.random.RandomState()
else:
self.rg = RandomGenerator(getattr(np.random.randomgen, brng)())
self.rg.random_sample()
self.int32info = np.iinfo(np.int32)
self.uint32info = np.iinfo(np.uint32)
self.uint64info = np.iinfo(np.uint64)

def time_raw(self, brng):
if brng == 'numpy':
self.rg.random_integers(self.int32info.max, size=nom_size)
else:
self.rg.random_integers(self.int32info.max, size=nom_size)

def time_32bit(self, brng):
min, max = self.uint32info.min, self.uint32info.max
self.rg.randint(min, max + 1, nom_size, dtype=np.uint32)

def time_64bit(self, brng):
min, max = self.uint64info.min, self.uint64info.max
self.rg.randint(min, max + 1, nom_size, dtype=np.uint64)

def time_normal_zig(self, brng):
self.rg.standard_normal(nom_size)

class Bounded(Benchmark):
u8 = np.uint8
u16 = np.uint16
u32 = np.uint32
u64 = np.uint64
param_names = ['rng', 'dt_max_masked']
params = [['DSFMT', 'PCG64', 'PCG32', 'MT19937', 'Xoroshiro128',
'Xorshift1024', 'Xoshiro256StarStar', 'Xoshiro512StarStar',
'Philox', 'ThreeFry', 'ThreeFry32', 'numpy'],
[[u8, 95, True],
[u8, 64, False], # Worst case for legacy
[u8, 95, False], # Typ. avg. case for legacy
[u8, 127, False], # Best case for legacy
[u16, 95, True],
[u16, 1024, False], # Worst case for legacy
[u16, 1535, False], # Typ. avg. case for legacy
[u16, 2047, False], # Best case for legacy
[u32, 95, True],
[u32, 1024, False], # Worst case for legacy
[u32, 1535, False], # Typ. avg. case for legacy
[u32, 2047, False], # Best case for legacy
[u64, 95, True],
[u64, 1024, False], # Worst case for legacy
[u64, 1535, False], # Typ. avg. case for legacy
[u64, 2047, False], # Best case for legacy
]]

def setup(self, brng, args):
if brng == 'numpy':
self.rg = np.random.RandomState()
else:
self.rg = RandomGenerator(getattr(np.random.randomgen, brng)())
self.rg.random_sample()

def time_bounded(self, brng, args):
"""
Timer for 8-bit bounded values.

Parameters (packed as args)
----------
dt : {uint8, uint16, uint32, unit64}
output dtype
max : int
Upper bound for range. Lower is always 0. Must be <= 2**bits.
use_masked: bool
If True, masking and rejection sampling is used to generate a random
number in an interval. If False, Lemire's algorithm is used if
available to generate a random number in an interval.

Notes
-----
Lemire's algorithm has improved performance when max+1 is not a
power of two.
"""
dt, max, use_masked = args
if brng == 'numpy':
self.rg.randint(0, max + 1, nom_size, dtype=dt)
else:
self.rg.randint(0, max + 1, nom_size, dtype=dt,
use_masked=use_masked)

6 changes: 1 addition & 5 deletions doc/DISTUTILS.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -319,11 +319,7 @@ and :c:data:`/**end repeat**/` lines, which may also be nested using
consecutively numbered delimiting lines such as :c:data:`/**begin repeat1`
and :c:data:`/**end repeat1**/`. String replacement specifications are started
and terminated using :c:data:`#`. This may be clearer in the following
template source example:

.. code-block:: C
:linenos:
:emphasize-lines: 3, 13, 29, 31
template source example::

/* TIMEDELTA to non-float types */

Expand Down
6 changes: 4 additions & 2 deletions doc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ FILES=
# Internal variables.
PAPEROPT_a4 = -D latex_paper_size=a4
PAPEROPT_letter = -D latex_paper_size=letter
ALLSPHINXOPTS = -d build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
ALLSPHINXOPTS = -WT --keep-going -d build/doctrees $(PAPEROPT_$(PAPER)) \
$(SPHINXOPTS) source

.PHONY: help clean html web pickle htmlhelp latex changes linkcheck \
dist dist-build gitwash-update
Expand All @@ -41,7 +42,8 @@ help:
@echo " upload USERNAME=... RELEASE=... to upload built docs to docs.scipy.org"

clean:
-rm -rf build/* source/reference/generated
-rm -rf build/*
find . -name generated -type d -prune -exec rm -rf "{}" ";"

gitwash-update:
rm -rf source/dev/gitwash
Expand Down
37 changes: 32 additions & 5 deletions doc/release/1.17.0-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ New functions
Deprecations
============

``np.polynomial`` functions warn when passed ``float``s in place of ``int``s
----------------------------------------------------------------------------
Previously functions in this module would accept ``float``s provided their
values were integral. For consistency with the rest of numpy, doing so is now
deprecated, and in future will raise a ``TypeError``.
``np.polynomial`` functions warn when passed ``float`` in place of ``int``
--------------------------------------------------------------------------
Previously functions in this module would accept ``float`` values provided they
were integral (``1.0``, ``2.0``, etc). For consistency with the rest of numpy,
doing so is now deprecated, and in future will raise a ``TypeError``.

Similarly, passing a float like ``0.5`` in place of an integer will now raise a
``TypeError`` instead of the previous ``ValueError``.
Expand Down Expand Up @@ -72,6 +72,11 @@ Looking up ``__buffer__`` attribute in `numpy.frombuffer` was undocumented and
non-functional. This code was removed. If needed, use
``frombuffer(memoryview(obj), ...)`` instead.

``out``is buffered for memory overlaps in ``np.take``, ``np.choose``, ``np.put``
--------------------------------------------------------------------------------
If the out argument to these functions is provided and has memory overlap with
the other arguments, it is now buffered to avoid order-dependent behavior.


C API changes
=============
Expand Down Expand Up @@ -119,6 +124,10 @@ divmod operation is now supported for two ``timedelta64`` operands
The divmod operator now handles two ``np.timedelta64`` operands, with
type signature mm->qm.

New mode "empty" for ``np.pad``
-------------------------------
This mode pads an array to a desired shape without initializing the new
entries.

Improvements
============
Expand Down Expand Up @@ -171,11 +180,29 @@ but with this change, you can do::

thereby saving a level of indentation

Improve performance of ``np.pad``
---------------------------------
The performance of the function has been improved for most cases by filling in
a preallocated array with the desired padded shape instead of using
concatenation.

``np.interp`` handles infinities more robustly
----------------------------------------------
In some cases where ``np.interp`` would previously return ``np.nan``, it now
returns an appropriate infinity.

Specialized ``np.isnan``, ``np.isinf``, and ``np.isfinite`` ufuncs for bool and int types
-----------------------------------------------------------------------------------------
The boolean and integer types are incapable of storing ``np.nan`` and ``np.inf`` values,
which allows us to provide specialized ufuncs that are up to 250x faster than the current
approach.

New keywords added to ``np.nan_to_num``
---------------------------------------
``np.nan_to_num`` now accepts keywords ``nan``, ``posinf`` and ``neginf`` allowing the
user to define the value to replace the ``nan``, positive and negative ``np.inf`` values
respectively.


Changes
=======
Expand Down
25 changes: 19 additions & 6 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,19 @@

sys.path.insert(0, os.path.abspath('../sphinxext'))

extensions = ['sphinx.ext.autodoc', 'numpydoc',
'sphinx.ext.intersphinx', 'sphinx.ext.coverage',
'sphinx.ext.doctest', 'sphinx.ext.autosummary',
'sphinx.ext.graphviz', 'sphinx.ext.ifconfig',
'matplotlib.sphinxext.plot_directive']
extensions = [
'sphinx.ext.autodoc',
'numpydoc',
'sphinx.ext.intersphinx',
'sphinx.ext.coverage',
'sphinx.ext.doctest',
'sphinx.ext.autosummary',
'sphinx.ext.graphviz',
'sphinx.ext.ifconfig',
'matplotlib.sphinxext.plot_directive',
'IPython.sphinxext.ipython_console_highlighting',
'IPython.sphinxext.ipython_directive',
]

if sphinx.__version__ >= "1.4":
extensions.append('sphinx.ext.imgmath')
Expand Down Expand Up @@ -234,7 +242,7 @@ def setup(app):
# -----------------------------------------------------------------------------

import glob
autosummary_generate = glob.glob("reference/*.rst")
autosummary_generate = True

# -----------------------------------------------------------------------------
# Coverage checker
Expand Down Expand Up @@ -355,3 +363,8 @@ def linkcode_resolve(domain, info):
else:
return "https://github.com/numpy/numpy/blob/v%s/numpy/%s%s" % (
numpy.__version__, fn, linespec)

doctest_global_setup = '''
import numpy as np
from numpy.random import randomgen
'''
3 changes: 3 additions & 0 deletions doc/source/dev/development_environment.rst
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,9 @@ the interpreter, tests can be run like this::
>>> np.test('full') # Also run tests marked as slow
>>> np.test('full', verbose=2) # Additionally print test name/file

An example of a successful test :
``4686 passed, 362 skipped, 9 xfailed, 5 warnings in 213.99 seconds``

Or a similar way from the command line::

$ python -c "import numpy as np; np.test()"
Expand Down
2 changes: 1 addition & 1 deletion doc/source/docs/howto_build_docs.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Building the NumPy API and reference docs
=========================================

We currently use Sphinx_ for generating the API and reference
documentation for NumPy. You will need Sphinx 1.0.1 or newer.
documentation for NumPy. You will need Sphinx 1.8.3 or newer.

If you only want to get the documentation, note that pre-built
versions can be found at
Expand Down
Binary file not shown.
Binary file added doc/source/papers/random123sc11.pdf
Binary file not shown.
Loading