[ Web Proxy ]
URL:
Viewing: https://numpy.org/doc/stable/reference/generated/../generated/numpy.dtype.num.html [Back]  [Original]

numpy.dtype.num — NumPy v2.5 Manual
Back to top
Search the docs ...:

numpy.dtype.num#

attribute

dtype.num#

A unique number for each of the 21 different built-in types.

These are roughly ordered from least-to-most precision.

Examples

Try it in your browser!
>>> import numpy as np
>>> dt = np.dtype(str)
>>> dt.num
19
>>> dt = np.dtype(float)
>>> dt.num
12

Web Proxy Viewer  |  New URL  |  Original Page