f19ebde9774b8c7117197f521d2ca311756161f6,deepchem/utils/test/test_api.py,TestAPI,test_singletask_rf_ECFP_regression_API,#TestAPI#,103

Before Change


    complex_featurizers = []
    input_transforms = []
    output_transforms = ["normalize"]
    task_type = "regression"
    model_params = {"batch_size": 5}
    model_name = "rf_regressor"
    input_file = "example.csv"
    tasks = ["log-solubility"]
    self._create_model(splittype, compound_featurizers, complex_featurizers, input_transforms,
                       output_transforms, task_type, model_params, model_name,
                       input_file=input_file, tasks=tasks)


  def test_singletask_rf_RDKIT_descriptor_regression_API(self):
    Test of singletask RF RDKIT-descriptor regression API.

After Change



    return train_dataset, test_dataset

  def test_singletask_rf_ECFP_regression_API(self):
    Test of singletask RF ECFP regression API.
    splittype = "scaffold"
    compound_featurizers = [CircularFingerprint(size=1024)]
    complex_featurizers = []
    input_transforms = []
    output_transforms = ["normalize"]
    model_params = {"batch_size": 5}
    task_types = {"log-solubility": "regression"}
    input_file = "example.csv"
    train_dataset, test_dataset = self._featurize_train_test_split(splittype, compound_featurizers, 
                                                    complex_featurizers, input_transforms,
                                                    output_transforms, input_file, task_types.keys())
    model_params["data_shape"] = train_dataset.get_data_shape()

    from sklearn.ensemble import RandomForestRegressor
    model = SklearnModel(task_types, model_params, model_instance=RandomForestRegressor())
    self._create_model(train_dataset, test_dataset, model)


  def test_singletask_rf_RDKIT_descriptor_regression_API(self):
    Test of singletask RF RDKIT-descriptor regression API.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 17

Instances


Project Name: deepchem/deepchem
Commit Name: f19ebde9774b8c7117197f521d2ca311756161f6
Time: 2016-02-01
Author: evan.n.feinberg@gmail.com
File Name: deepchem/utils/test/test_api.py
Class Name: TestAPI
Method Name: test_singletask_rf_ECFP_regression_API


Project Name: deepchem/deepchem
Commit Name: f19ebde9774b8c7117197f521d2ca311756161f6
Time: 2016-02-01
Author: evan.n.feinberg@gmail.com
File Name: deepchem/utils/test/test_api.py
Class Name: TestAPI
Method Name: test_singletask_rf_ECFP_regression_API


Project Name: deepchem/deepchem
Commit Name: f19ebde9774b8c7117197f521d2ca311756161f6
Time: 2016-02-01
Author: evan.n.feinberg@gmail.com
File Name: deepchem/utils/test/test_api.py
Class Name: TestAPI
Method Name: test_singletask_mlp_NNScore_regression_API


Project Name: deepchem/deepchem
Commit Name: f19ebde9774b8c7117197f521d2ca311756161f6
Time: 2016-02-01
Author: evan.n.feinberg@gmail.com
File Name: deepchem/utils/test/test_api.py
Class Name: TestAPI
Method Name: test_singletask_rf_RDKIT_descriptor_regression_API