Skip to content

DOC: Fix reference warning in some rst and code files. #24487

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

Merged
merged 1 commit into from
Sep 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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 doc/source/reference/arrays.dtypes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ String with comma-separated fields
>>> dt = np.dtype("a3, 3u8, (3,4)a10")

Type strings
Any string in :obj:`numpy.sctypeDict`.keys():
Any string name of a NumPy dtype, e.g.:

.. admonition:: Example

Expand Down
5 changes: 2 additions & 3 deletions doc/source/reference/routines.array-creation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ From existing data
Creating record arrays
----------------------

.. note:: :mod:`numpy.core.records` is used to create record
array. Please refer to :ref:`arrays.classes.rec` for
.. note:: Please refer to :ref:`arrays.classes.rec` for
record arrays.

.. autosummary::
Expand All @@ -66,7 +65,7 @@ Creating character arrays (:mod:`numpy.char`)
---------------------------------------------

.. note:: :mod:`numpy.char` is the preferred alias for
:mod:`numpy.core.defchararray`.
``numpy.core.defchararray`` module.

.. autosummary::
:toctree: generated/
Expand Down
2 changes: 1 addition & 1 deletion doc/source/release/1.16.0-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ New deprecations

* The type dictionaries `numpy.core.typeNA` and `numpy.core.sctypeNA` are
deprecated. They were buggy and not documented and will be removed in the
1.18 release. Use `numpy.sctypeDict` instead.
1.18 release. Use ``numpy.sctypeDict`` instead.

* The `numpy.asscalar` function is deprecated. It is an alias to the more
powerful `numpy.ndarray.item`, not tested, and fails for scalars.
Expand Down
4 changes: 2 additions & 2 deletions doc/source/release/1.20.0-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -824,7 +824,7 @@ Callback functions in f2py are now thread safe.

`numpy.core.records.fromfile` now supports file-like objects
------------------------------------------------------------
`numpy.rec.fromfile` can now use file-like objects, for instance
`numpy.core.records.fromfile` can now use file-like objects, for instance
:py:class:`io.BytesIO`

(`gh-16675 <https://github.com/numpy/numpy/pull/16675>`__)
Expand All @@ -839,7 +839,7 @@ Use f90 compiler specified by the command line args
---------------------------------------------------

The compiler command selection for Fortran Portland Group Compiler is changed
in `numpy.distutils.fcompiler`. This only affects the linking command. This
in ``numpy.distutils.fcompiler``. This only affects the linking command. This
forces the use of the executable provided by the command line option (if
provided) instead of the pgfortran executable. If no executable is provided to
the command line option it defaults to the pgf90 executable, which is an alias
Expand Down
2 changes: 1 addition & 1 deletion doc/source/release/1.20.2-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ A total of 20 pull requests were merged for this release.
* `#18488 <https://github.com/numpy/numpy/pull/18488>`__: BUG: check if PyArray_malloc succeeded
* `#18546 <https://github.com/numpy/numpy/pull/18546>`__: BUG: incorrect error fallthrough in nditer
* `#18559 <https://github.com/numpy/numpy/pull/18559>`__: CI: Backport CI fixes from main.
* `#18599 <https://github.com/numpy/numpy/pull/18599>`__: MAINT: Add annotations for `dtype.__getitem__`, `__mul__` and...
* `#18599 <https://github.com/numpy/numpy/pull/18599>`__: MAINT: Add annotations for ``dtype.__getitem__``, `__mul__` and...
* `#18611 <https://github.com/numpy/numpy/pull/18611>`__: BUG: NameError in numpy.distutils.fcompiler.compaq
* `#18612 <https://github.com/numpy/numpy/pull/18612>`__: BUG: Fixed ``where`` keyword for ``np.mean`` & ``np.var`` methods
* `#18617 <https://github.com/numpy/numpy/pull/18617>`__: CI: Update apt package list before Python install
Expand Down
2 changes: 1 addition & 1 deletion doc/source/release/1.7.0-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ General
-------

Specifying a custom string formatter with a `_format` array attribute is
deprecated. The new `formatter` keyword in ``numpy.set_printoptions`` or
deprecated. The new ``formatter`` keyword in ``numpy.set_printoptions`` or
``numpy.array2string`` can be used instead.

The deprecated imports in the polynomial package have been removed.
Expand Down
2 changes: 1 addition & 1 deletion doc/source/user/basics.indexing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ regardless of whether those values are :py:data:`True` or

A common use case for this is filtering for desired element values.
For example, one may wish to select all entries from an array which
are not :const:`NaN`::
are not :const:`numpy.nan`::

>>> x = np.array([[1., 2.], [np.nan, 3.], [np.nan, np.nan]])
>>> x[~np.isnan(x)]
Expand Down
4 changes: 2 additions & 2 deletions numpy/typing/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@
Record array dtypes
~~~~~~~~~~~~~~~~~~~

The dtype of `numpy.recarray`, and the `numpy.rec` functions in general,
can be specified in one of two ways:
The dtype of `numpy.recarray`, and the :ref:`routines.array-creation.rec`
functions in general, can be specified in one of two ways:

* Directly via the ``dtype`` argument.
* With up to five helper arguments that operate via `numpy.format_parser`:
Expand Down