diff options
author | mattip <matti.picus@gmail.com> | 2019-03-16 21:46:59 +0200 |
---|---|---|
committer | mattip <matti.picus@gmail.com> | 2019-03-17 09:05:25 +0200 |
commit | 32129453da0f9bf0f352adaaff79f884d2bf52bc (patch) | |
tree | b7ce2d438f054385ebc5648a0e136b24cdbdfbfe /numpy/lib/npyio.py | |
parent | bee436da4efb2240752eea751971aa6ea5a3bb48 (diff) | |
download | numpy-32129453da0f9bf0f352adaaff79f884d2bf52bc.tar.gz |
DEV: cleanup imports and some assignments (from LGTM)
Diffstat (limited to 'numpy/lib/npyio.py')
-rw-r--r-- | numpy/lib/npyio.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/numpy/lib/npyio.py b/numpy/lib/npyio.py index 1e43fdb34..d702859fa 100644 --- a/numpy/lib/npyio.py +++ b/numpy/lib/npyio.py @@ -23,8 +23,7 @@ from ._iotools import ( ) from numpy.compat import ( - asbytes, asstr, asunicode, asbytes_nested, bytes, basestring, unicode, - os_fspath, os_PathLike, pickle + asbytes, asstr, asunicode, bytes, basestring, os_fspath, os_PathLike, pickle ) if sys.version_info[0] >= 3: @@ -1123,7 +1122,6 @@ def loadtxt(fname, dtype=float, comments='#', delimiter=None, if type(x) is bytes: return conv(x) return conv(x.encode("latin1")) - import functools converters[i] = functools.partial(tobytes_first, conv=conv) else: converters[i] = conv @@ -1974,7 +1972,6 @@ def genfromtxt(fname, dtype=float, comments='#', delimiter=None, if type(x) is bytes: return conv(x) return conv(x.encode("latin1")) - import functools user_conv = functools.partial(tobytes_first, conv=conv) else: user_conv = conv |