Commit 8d016c12 authored by Nikita Titov's avatar Nikita Titov Committed by Guolin Ke
Browse files

removed outdated code (#1084)

parent 750a11b0
...@@ -273,12 +273,6 @@ class LGBMModel(_LGBMModelBase): ...@@ -273,12 +273,6 @@ class LGBMModel(_LGBMModelBase):
def get_params(self, deep=True): def get_params(self, deep=True):
params = super(LGBMModel, self).get_params(deep=deep) params = super(LGBMModel, self).get_params(deep=deep)
params.update(self._other_params) params.update(self._other_params)
if 'seed' in params:
warnings.warn('The `seed` parameter is deprecated and will be removed in 2.0.12 version. '
'Please use `random_state` instead.', LGBMDeprecationWarning)
if 'nthread' in params:
warnings.warn('The `nthread` parameter is deprecated and will be removed in 2.0.12 version. '
'Please use `n_jobs` instead.', LGBMDeprecationWarning)
return params return params
# minor change to support `**kwargs` # minor change to support `**kwargs`
...@@ -578,16 +572,6 @@ class LGBMModel(_LGBMModelBase): ...@@ -578,16 +572,6 @@ class LGBMModel(_LGBMModelBase):
raise LGBMNotFittedError('No feature_importances found. Need to call fit beforehand.') raise LGBMNotFittedError('No feature_importances found. Need to call fit beforehand.')
return self.booster_.feature_importance() return self.booster_.feature_importance()
def booster(self):
warnings.warn('The `booster()` method is deprecated and will be removed in 2.0.12 version. '
'Please use attribute `booster_` instead.', LGBMDeprecationWarning)
return self.booster_
def feature_importance(self):
warnings.warn('The `feature_importance()` method is deprecated and will be removed in 2.0.12 version. '
'Please use attribute `feature_importances_` instead.', LGBMDeprecationWarning)
return self.feature_importances_
class LGBMRegressor(LGBMModel, _LGBMRegressorBase): class LGBMRegressor(LGBMModel, _LGBMRegressorBase):
"""LightGBM regressor.""" """LightGBM regressor."""
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment