8000 DOC: fix doc linking, was referencing private submodules. · numpy/numpy@307c679 · GitHub
[go: up one dir, main page]

Skip to content

Commit 307c679

Browse files
rgommerscharris
authored andcommitted
DOC: fix doc linking, was referencing private submodules.
Closes gh-14359
1 parent 597fc07 commit 307c679

File tree

7 files changed

+16
-26
lines changed
10000

7 files changed

+16
-26
lines changed

doc/source/reference/random/bit_generators/mt19937.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
1-
Mersenne Twister (MT19937)
1+
Mersenne Twister (MT19937)
22
--------------------------
33

4-
.. module:: numpy.random.mt19937
5-
6-
.. currentmodule:: numpy.random.mt19937
4+
.. currentmodule:: numpy.random
75

86
.. autoclass:: MT19937
97
:exclude-members:

doc/source/reference/random/bit_generators/pcg64.rst

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
Parallel Congruent Generator (64-bit, PCG64)
22
--------------------------------------------
33

4-
.. module:: numpy.random.pcg64
5-
6-
.. currentmodule:: numpy.random.pcg64
4+
.. currentmodule:: numpy.random
75

86
.. autoclass:: PCG64
97
:exclude-members:

doc/source/reference/random/bit_generators/philox.rst

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
Philox Counter-based RNG
22
------------------------
33

4-
.. module:: numpy.random.philox
5-
6-
.. currentmodule:: numpy.random.philox
4+
.. currentmodule:: numpy.random
75

86
.. autoclass:: Philox
97
:exclude-members:

doc/source/reference/random/bit_generators/sfc64.rst

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
SFC64 Small Fast Chaotic PRNG
22
-----------------------------
33

4-
.. module:: numpy.random.sfc64
5-
6-
.. currentmodule:: numpy.random.sfc64
4+
.. currentmodule:: numpy.random
75

86
.. autoclass:: SFC64
97
:exclude-members:

doc/source/reference/random/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ Concepts
190190
:maxdepth: 1
191191

192192
generator
193-
legacy mtrand <legacy>
193+
Legacy generator and functions <legacy>
194194
BitGenerators, SeedSequences <bit_generators/index>
195195

196196
Features

doc/source/reference/random/legacy.rst

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,27 @@
44

55
Legacy Random Generation
66
------------------------
7-
The `~mtrand.RandomState` provides access to
7+
The `RandomState` provides access to
88
legacy generators. This generator is considered frozen and will have
99
no further improvements. It is guaranteed to produce the same values
1010
as the final point release of NumPy v1.16. These all depend on Box-Muller
1111
normals or inverse CDF exponentials or gammas. This class should only be used
1212
if it is essential to have randoms that are identical to what
1313
would have been produced by previous versions of NumPy.
1414

15-
`~mtrand.RandomState` adds additional information
15+
`RandomState` adds additional information
1616
to the state which is required when using Box-Muller normals since these
1717
are produced in pairs. It is important to use
18-
`~mtrand.RandomState.get_state`, and not the underlying bit generators
18+
`RandomState.get_state`, and not the underlying bit generators
1919
`state`, when accessing the state so that these extra values are saved.
2020

21-
Although we provide the `~mt19937.MT19937` BitGenerator for use independent of
22-
`~mtrand.RandomState`, note that its default seeding uses `~SeedSequence`
23-
rather than the legacy seeding algorithm. `~mtrand.RandomState` will use the
21+
Although we provide the `MT19937` BitGenerator for use independent of
22+
`RandomState`, note that its default seeding uses `SeedSequence`
23+
rather than the legacy seeding algorithm. `RandomState` will use the
2424
legacy seeding algorithm. The methods to use the legacy seeding algorithm are
2525
currently private as the main reason to use them is just to implement
26-
`~mtrand.RandomState`. However, one can reset the state of `~mt19937.MT19937`
27-
using the state of the `~mtrand.RandomState`:
26+
`RandomState`. However, one can reset the state of `MT19937`
27+
using the state of the `RandomState`:
2828

2929
.. code-block:: python
3030
@@ -47,8 +47,6 @@ using the state of the `~mtrand.RandomState`:
4747
rs2.standard_exponential()
4848
4949
50-
.. currentmodule:: numpy.random.mtrand
51-
5250
.. autoclass:: RandomState
5351
:exclude-members:
5452

numpy/random/mtrand.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ cdef class RandomState:
8383
See Also
8484
--------
8585
Generator
86-
mt19937.MT19937
87-
Bit_Generators
86+
MT19937
87+
:ref:`bit_generator`
8888
8989
"""
9090
cdef public object _bit_generator

0 commit comments

Comments
 (0)
0