You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
output array data type. If ``dtype`` is ``None``, the output array data type must be inferred from the data type(s) in ``obj``. If all input values are Python scalars, then
45
45
46
46
- if all values are of type ``bool``, the output data type must be ``bool``.
47
-
- if the values are a mixture of ``bool``s and ``int``, the output data type must be the default integer data type.
48
-
- if one or more values are ``float``s, the output data type must be the default floating-point data type.
47
+
- if the values are a mixture of ``bool``\s and ``int``, the output data type must be the default integer data type.
48
+
- if one or more values are ``float``\s, the output data type must be the default floating-point data type.
49
49
50
50
Default: ``None``.
51
-
52
-
**Note**
53
-
54
-
If ``dtype`` is not ``None``, then array conversions should obey :ref:`type-promotion` rules. Conversions not specified according to :ref:`type-promotion` rules may or may not be permitted by a conforming array library.
55
-
To perform an explicit cast, use :ref:`function-astype`.
56
51
device: Optional[device]
57
52
device on which to place the created array. If ``device`` is ``None`` and ``x`` is an array, the output array device must be inferred from ``x``. Default: ``None``.
- If ``dtype`` is not ``None``, then array conversions should obey :ref:`type-promotion` rules. Conversions not specified according to :ref:`type-promotion` rules may or may not be permitted by a conforming array library. To perform an explicit cast, use :ref:`function-astype`.
0 commit comments