MNT Replace externals.six.integer_types with int
@@ -23,7 +23,6 @@ from ..utils.multiclass import check_classification_targets
from ..utils.random import check_random_state
from ..utils.validation import (check_is_fitted, check_array, check_X_y,
check_scalar)
-from ..externals.six import integer_types
from ..exceptions import ConvergenceWarning
@@ -300,8 +299,7 @@ class NeighborhoodComponentsAnalysis(BaseEstimator, TransformerMixin):
# Check the preferred dimensionality of the projected space
if self.n_components is not None:
- check_scalar(self.n_components, 'n_components',
- integer_types, 1)
+ check_scalar(self.n_components, 'n_components', int, 1)
if self.n_components > X.shape[1]:
raise ValueError('The preferred dimensionality of the '
@@ -320,9 +318,9 @@ class NeighborhoodComponentsAnalysis(BaseEstimator, TransformerMixin):
.format(X.shape[1],
self.components_.shape[1]))
- check_scalar(self.max_iter, 'max_iter', integer_types, 1)
+ check_scalar(self.max_iter, 'max_iter', int, 1)
check_scalar(self.tol, 'tol', float, 0.)
- check_scalar(self.verbose, 'verbose', integer_types, 0)
+ check_scalar(self.verbose, 'verbose', int, 0)
if self.callback is not None:
if not callable(self.callback):
