6251434bd1d71c960b1ac340f4645d9e8439ca86,autosklearn/pipeline/components/data_preprocessing/one_hot_encoding/one_hot_encoding.py,OneHotEncoder,fit,#OneHotEncoder#Any#Any#,22
Before Change
self.categorical_features = categorical_features
def fit(self, X, y=None):
if self.use_minimum_fraction is None or \
self.use_minimum_fraction is False or \
(isinstance(self.use_minimum_fraction, str) and
self.use_minimum_fraction.lower() == "false"):
self.minimum_fraction = None
else:
self.minimum_fraction = float(self.minimum_fraction)
if self.categorical_features is None:
categorical_features = []
else:
categorical_features = self.categorical_features
self.preprocessor = autosklearn.pipeline.implementations.OneHotEncoder\
.OneHotEncoder(minimum_fraction=self.minimum_fraction,
categorical_features=categorical_features)
self.preprocessor = self.preprocessor.fit(X)
return self
def transform(self, X):
import scipy.sparse
After Change
return self.preprocessor.fit_transform(X)
def fit(self, X, y=None):
self._fit(X, y)
return self
def fit_transform(self, X, y=None):
return self._fit(X, y)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 12
Instances
Project Name: automl/auto-sklearn
Commit Name: 6251434bd1d71c960b1ac340f4645d9e8439ca86
Time: 2017-11-21
Author: feurerm@informatik.uni-freiburg.de
File Name: autosklearn/pipeline/components/data_preprocessing/one_hot_encoding/one_hot_encoding.py
Class Name: OneHotEncoder
Method Name: fit
Project Name: automl/auto-sklearn
Commit Name: 6251434bd1d71c960b1ac340f4645d9e8439ca86
Time: 2017-11-21
Author: feurerm@informatik.uni-freiburg.de
File Name: autosklearn/pipeline/components/feature_preprocessing/random_trees_embedding.py
Class Name: RandomTreesEmbedding
Method Name: fit
Project Name: automl/auto-sklearn
Commit Name: 6251434bd1d71c960b1ac340f4645d9e8439ca86
Time: 2017-11-21
Author: feurerm@informatik.uni-freiburg.de
File Name: autosklearn/pipeline/components/feature_preprocessing/fast_ica.py
Class Name: FastICA
Method Name: fit