16598a0bb84e5980d3ac6f333f8249b5887fa2d0,heamy/dataset.py,Dataset,_setup_data,#Dataset#Any#Any#Any#Any#,146

Before Change


        self._X_train = X_train
        self._X_test = X_test

        if isinstance(y_train, (pd.Series, pd.DataFrame)):
            self._y_train = y_train.values
        else:
            self._y_train = y_train

        if isinstance(y_test, (pd.Series, pd.DataFrame)):
            self._y_test = y_test.values
        else:
            self._y_test = y_test

After Change


        self._X_test = self._validate_data(X_test)

        self._y_train = self._validate_data(y_train, only_numpy=True)
        self._y_test = self._validate_data(y_test, only_numpy=True)

    def _validate_data(self, data, only_numpy=False):
        if not only_numpy:
            dtypes = (pd.Series, pd.DataFrame, np.ndarray)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 2

Instances


Project Name: rushter/heamy
Commit Name: 16598a0bb84e5980d3ac6f333f8249b5887fa2d0
Time: 2017-01-27
Author: me@rushter.com
File Name: heamy/dataset.py
Class Name: Dataset
Method Name: _setup_data


Project Name: sebp/scikit-survival
Commit Name: fbf10559a0b3707bcb9b192d3121314402c84a78
Time: 2021-03-06
Author: sebp@k-d-w.org
File Name: sksurv/ensemble/boosting.py
Class Name: ComponentwiseGradientBoostingSurvivalAnalysis
Method Name: predict


Project Name: scikit-learn/scikit-learn
Commit Name: e970678d95f88bf5a793c4686f3a5a341bfb002c
Time: 2020-11-20
Author: thomasjpfan@gmail.com
File Name: sklearn/cluster/_feature_agglomeration.py
Class Name: AgglomerationTransform
Method Name: transform