diff options
Diffstat (limited to 'numpy/lib/function_base.py')
-rw-r--r-- | numpy/lib/function_base.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/numpy/lib/function_base.py b/numpy/lib/function_base.py index 914d7b580..fdcb4977a 100644 --- a/numpy/lib/function_base.py +++ b/numpy/lib/function_base.py @@ -1,4 +1,4 @@ -from __future__ import division +from __future__ import division, absolute_import __docformat__ = "restructuredtext en" __all__ = ['select', 'piecewise', 'trim_zeros', 'copy', 'iterable', @@ -26,11 +26,11 @@ from numpy.core.fromnumeric import ravel, nonzero, choose, sort, mean from numpy.core.numerictypes import typecodes, number from numpy.core import atleast_1d, atleast_2d from numpy.lib.twodim_base import diag -from _compiled_base import _insert, add_docstring -from _compiled_base import digitize, bincount, interp as compiled_interp -from arraysetops import setdiff1d -from utils import deprecate -from _compiled_base import add_newdoc_ufunc +from ._compiled_base import _insert, add_docstring +from ._compiled_base import digitize, bincount, interp as compiled_interp +from .arraysetops import setdiff1d +from .utils import deprecate +from ._compiled_base import add_newdoc_ufunc import numpy as np import collections @@ -2589,7 +2589,7 @@ def _chbevl(x, vals): b0 = vals[0] b1 = 0.0 - for i in xrange(1,len(vals)): + for i in range(1,len(vals)): b2 = b1 b1 = b0 b0 = x*b1 - b2 + vals[i] @@ -3467,7 +3467,7 @@ def delete(arr, obj, axis=None): new[slobj] = arr[slobj2] elif isinstance(obj, slice): start, stop, step = obj.indices(N) - numtodel = len(xrange(start, stop, step)) + numtodel = len(list(range(start, stop, step))) if numtodel <= 0: if wrap: return wrap(new) |