-
-
Notifications
You must be signed in to change notification settings - Fork 10.9k
DOC: np.random documentation cleanup and expansion. #13849
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
Conversation
from numpy.random import Generator, PCG64 | ||
rg = Generator(PCG64()) | ||
from numpy.random import default_gen | ||
rg = default_gen(12345) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops. This depends on #13840
Test failure looks unrelated. |
According to #13829 (comment)
would help forestall PRs with unacceptable changes |
Does this supersede #13675? |
Yes. |
|
||
.. [1] The algorithm is carefully designed to eliminate a number of possible | ||
ways to collide. For example, if one only does one level of spawning, it | ||
is guaranteed that all states will be unique. But it's easier to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh, here is the guarantee. Stream of comments...
estimate the naive upper bound on a napkin and take comfort knowing | ||
that the probability is actually lower. | ||
|
||
.. [2] In this calculation, we can ignore the amount of numbers drawn from each |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same "ahh" here. Should do a review.
LGTM. Minor comments that were mostly already addressed. |
DOC: fix reference links
Also, make the jump step odd to make it a proper Weyl generator. No, this will never, ever, ever, ever matter. But it feels nicer.
""" | ||
step = 0x9e3779b97f4a7c15f39cc0605cedc834 | ||
step = 0x9e3779b97f4a7c15f39cc0605cedc835 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I need a LGTM on this one last non-trivial bit, then we can merge this. @bashtage ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feel free to round it which ever way that you prefer. LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
8000 option>Thank you for your indulgence. :-)
@charris This is ready to go once the last CI finishes. |
Thanks Robert. |
I've corrected some errors, filled in some gaps, and extended some of the commentary.