ef29cd9bde8695645d63ae7f568fb298809e7b19,tpot/builtins/dataset_selector.py,DatasetSelector,fit,#DatasetSelector#Any#Any#,43

Before Change


        features_i_df = pd.read_csv(self.subset_i, sep="\t", header=0)
        if isinstance(X, pd.DataFrame): // use columns" names
            self.feature_names = list(X.columns.values)
            feature_i = [str(val) for val in features_i_df.values.flatten()]
        elif isinstance(X, np.ndarray): // use index
            self.feature_names = list(range(X.shape[1]))
            feature_i = [int(val) for val in features_i_df.values.flatten()]

After Change


        subset_df = pd.read_csv(self.subset_list, header=0, index_col=0)

        if isinstance(self.sel_subset, int):
            self.sel_subset_name = subset_df.index[self.sel_subset]
        elif isinstance(self.sel_subset, list):
            self.sel_subset_name = []
            for s in self.sel_subset:
                if isinstance(s, int):
                    self.sel_subset_name.append(subset_df.index[s])
                else:
                    self.sel_subset_name.append(s)
        else: // self.sel_subset is a string
            self.sel_subset_name = self.sel_subset

        sel_features = subset_df.loc[self.sel_subset_name, "Features"]
        if not isinstance(sel_features, str):
            sel_features = ";".join(sel_features.tolist())

        sel_uniq_features = set(sel_features.split(""))

        if isinstance(X, pd.DataFrame): // use columns" names
            self.feature_names = list(X.columns.values)
        elif isinstance(X, np.ndarray): // use index
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: EpistasisLab/tpot
Commit Name: ef29cd9bde8695645d63ae7f568fb298809e7b19
Time: 2018-10-15
Author: weixuanf@pennmedicine.upenn.edu
File Name: tpot/builtins/dataset_selector.py
Class Name: DatasetSelector
Method Name: fit


Project Name: SheffieldML/GPy
Commit Name: 51ff92e59151a08a05097565457e113f9090b311
Time: 2013-04-11
Author: ibinbei@gmail.com
File Name: GPy/models/mrd.py
Class Name: MRD
Method Name: _log_likelihood_gradients


Project Name: rusty1s/pytorch_geometric
Commit Name: 3238295386c5c5e9d39ed770e92a54326430b8ae
Time: 2017-11-21
Author: matthias.fey@tu-dortmund.de
File Name: torch_geometric/visualization/mnist_graph.py
Class Name:
Method Name: