Skip to content

CLN: clean up unused imports #10130

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 14, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions pandas/core/base.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
"""
Base and utility classes for pandas objects.
"""
import datetime

from pandas import compat
import numpy as np
from pandas.core import common as com
import pandas.core.nanops as nanops
import pandas.tslib as tslib
import pandas.lib as lib
from pandas.util.decorators import Appender, cache_readonly
from pandas.core.strings import StringMethods
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/categorical.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
_possibly_infer_to_datetimelike, get_dtype_kinds,
is_list_like, is_sequence, is_null_slice, is_bool,
_ensure_platform_int, _ensure_object, _ensure_int64,
_coerce_indexer_dtype, _values_from_object, take_1d)
_coerce_indexer_dtype, take_1d)
from pandas.util.terminal import get_terminal_size
from pandas.core.config import get_option

Expand Down
5 changes: 3 additions & 2 deletions pandas/core/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,9 @@
from pandas.core.common import (isnull, notnull, PandasError, _try_sort,
_default_index, _maybe_upcast, is_sequence,
_infer_dtype_from_scalar, _values_from_object,
is_list_like, _get_dtype, _maybe_box_datetimelike,
is_categorical_dtype, is_object_dtype, _possibly_infer_to_datetimelike)
is_list_like, _maybe_box_datetimelike,
is_categorical_dtype, is_object_dtype,
_possibly_infer_to_datetimelike)
from pandas.core.generic import NDFrame, _shared_docs
from pandas.core.index import Index, MultiIndex, _ensure_index
from pandas.core.indexing import (maybe_droplevels,
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import pandas.core.common as com
import pandas.core.datetools as datetools
from pandas import compat
from pandas.compat import map, zip, lrange, string_types, isidentifier, lmap
from pandas.compat import map, zip, lrange, string_types, isidentifier
from pandas.core.common import (isnull, notnull, is_list_like,
_values_from_object, _maybe_promote,
_maybe_box_datetimelike, ABCSeries,
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/groupby.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from pandas.core.categorical import Categorical
from pandas.core.frame import DataFrame
from pandas.core.generic import NDFrame
from pandas.core.index import Index, MultiIndex, CategoricalIndex, _ensure_index, _union_indexes
from pandas.core.index import Index, MultiIndex, CategoricalIndex, _ensure_index
from pandas.core.internals import BlockManager, make_block
from pandas.core.series import Series
from pandas.core.panel import Panel
Expand Down
1 change: 0 additions & 1 deletion pandas/core/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
from pandas import compat
import numpy as np

from math import ceil
from sys import getsizeof
import pandas.tslib as tslib
import pandas.lib as lib
Expand Down
5 changes: 1 addition & 4 deletions pandas/core/indexing.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# pylint: disable=W0223

from datetime import datetime
from pandas.core.index import Index, MultiIndex, _ensure_index
from pandas.core.index import Index, MultiIndex
from pandas.compat import range, zip
import pandas.compat as compat
import pandas.core.common as com
Expand All @@ -10,8 +9,6 @@
is_null_slice,
ABCSeries, ABCDataFrame, ABCPanel, is_float,
_values_from_object, _infer_fill_value, is_integer)
import pandas.lib as lib

import numpy as np

# the supported indexers
Expand Down
3 changes: 0 additions & 3 deletions pandas/core/nanops.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import sys
import itertools
import functools

import numpy as np

try:
Expand All @@ -10,7 +8,6 @@
except ImportError: # pragma: no cover
_USE_BOTTLENECK = False

import pandas.core.common as com
import pandas.hashtable as _hash
from pandas import compat, lib, algos, tslib
from pandas.compat import builtins
Expand Down
2 changes: 0 additions & 2 deletions pandas/core/panel.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
from pandas.compat import (map, zip, range, lrange, lmap, u, OrderedDict,
OrderedDefaultdict)
from pandas import compat
import sys
import warnings
import numpy as np
from pandas.core.common import (PandasError, _try_sort, _default_index,
Expand All @@ -27,7 +26,6 @@
deprecate_kwarg)
import pandas.core.common as com
import pandas.core.ops as ops
import pandas.core.nanops as nanops
import pandas.computation.expressions as expressions
from pandas import lib

Expand Down
1 change: 0 additions & 1 deletion pandas/core/panelnd.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
""" Factory methods to create N-D panels """

import pandas.lib as lib
from pandas.compat import zip
import pandas.compat as compat

Expand Down
3 changes: 1 addition & 2 deletions pandas/core/reshape.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
from pandas._sparse import IntIndex

from pandas.core.categorical import Categorical
from pandas.core.common import (notnull, _ensure_platform_int, _maybe_promote,
isnull)
from pandas.core.common import notnull, _ensure_platform_int, _maybe_promote
from pandas.core.groupby import get_group_index, _compress_group_index

import pandas.core.common as com
Expand Down
4 changes: 2 additions & 2 deletions pandas/core/series.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
is_list_like, _values_from_object,
_possibly_cast_to_datetime, _possibly_castable,
_possibly_convert_platform, _try_sort,
ABCSparseArray, _maybe_match_name, _coerce_to_dtype,
_ensure_object, SettingWithCopyError,
ABCSparseArray, _maybe_match_name,
_coerce_to_dtype, SettingWithCopyError,
_maybe_box_datetimelike, ABCDataFrame)
from pandas.core.index import (Index, MultiIndex, InvalidIndexError,
_ensure_index)
Expand Down
4 changes: 2 additions & 2 deletions pandas/util/decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def deprecate_kwarg(old_arg_name, new_arg_name, mapping=None):
Name of prefered argument in function
mapping : dict or callable
If mapping is present, use it to translate old arguments to
new arguments. A callable must do its own value checking;
new arguments. A callable must do its own value checking;
values not found in a dict will be forwarded unchanged.

Examples
Expand All @@ -45,7 +45,7 @@ def deprecate_kwarg(old_arg_name, new_arg_name, mapping=None):
should raise warning
>>> f(cols='should error', columns="can't pass do both")
TypeError: Can only specify 'cols' or 'columns', not both
>>> @deprecate_kwarg('old', 'new', {'yes': True, 'no', False})
>>> @deprecate_kwarg('old', 'new', {'yes': True, 'no': False})
... def f(new=False):
... print('yes!' if new else 'no!')
...
Expand Down