diff options
author | Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> | 2021-10-07 14:29:40 +0200 |
---|---|---|
committer | Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> | 2023-02-10 00:06:49 +0100 |
commit | 75af40548eb85cfa25cb4074e9e4ebc5d5196b4e (patch) | |
tree | 9f5a39dd6cc62b66bb3753439003245960294350 /numpy/core/arrayprint.py | |
parent | ac6e66b9b22adcf1d72750ccb8ffe70be87c3679 (diff) | |
download | numpy-75af40548eb85cfa25cb4074e9e4ebc5d5196b4e.tar.gz |
MAINT, DOC: string_ → bytes_ and unicode_ → str_
Diffstat (limited to 'numpy/core/arrayprint.py')
-rw-r--r-- | numpy/core/arrayprint.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/numpy/core/arrayprint.py b/numpy/core/arrayprint.py index e0d8ab5c7..a243366b7 100644 --- a/numpy/core/arrayprint.py +++ b/numpy/core/arrayprint.py @@ -169,7 +169,7 @@ def set_printoptions(precision=None, threshold=None, edgeitems=None, - 'longfloat' : 128-bit floats - 'complexfloat' - 'longcomplexfloat' : composed of two 128-bit floats - - 'numpystr' : types `numpy.string_` and `numpy.unicode_` + - 'numpystr' : types `numpy.bytes_` and `numpy.str_` - 'object' : `np.object_` arrays Other keys that can be used to set a group of types at once are: @@ -475,7 +475,7 @@ def _get_format_function(data, **options): return formatdict['longcomplexfloat']() else: return formatdict['complexfloat']() - elif issubclass(dtypeobj, (_nt.unicode_, _nt.string_)): + elif issubclass(dtypeobj, (_nt.str_, _nt.bytes_)): return formatdict['numpystr']() elif issubclass(dtypeobj, _nt.datetime64): return formatdict['datetime']() @@ -616,7 +616,7 @@ def array2string(a, max_line_width=None, precision=None, - 'complexfloat' - 'longcomplexfloat' : composed of two 128-bit floats - 'void' : type `numpy.void` - - 'numpystr' : types `numpy.string_` and `numpy.unicode_` + - 'numpystr' : types `numpy.bytes_` and `numpy.str_` Other keys that can be used to set a group of types at once are: |