fe6205abaa39518b633df85a2f8b8a9a0a25a375,deepchem/splits/__init__.py,MolecularWeightSplitter,split,#MolecularWeightSplitter#Any#Any#Any#Any#Any#Any#,102

Before Change



    train_cutoff = frac_train * len(samples.compounds_df)
    valid_cutoff = (frac_train+frac_valid) * len(samples.compounds_df)
    shuffled = np.random.permutation(range(len(samples.compounds_df)))

    // log stats on MW in each dataset

    return (shuffled[:train_cutoff], shuffled[train_cutoff:valid_cutoff],

After Change


    df = samples.compounds_df
    mws = []
    for _, row in smiles_df.iterrows():
        mol = Chem.MolFromSmiles(row["smiles"])
        mw = Chem.rdMolDescriptors.CalcExactMolWt(mol)
        mws.append(mw)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: deepchem/deepchem
Commit Name: fe6205abaa39518b633df85a2f8b8a9a0a25a375
Time: 2016-04-05
Author: jgomes@berkeley.edu
File Name: deepchem/splits/__init__.py
Class Name: MolecularWeightSplitter
Method Name: split


Project Name: SheffieldML/GPy
Commit Name: 350497c72606f188f83b68588140f0058190559b
Time: 2013-04-16
Author: ibinbei@gmail.com
File Name: GPy/models/mrd.py
Class Name: MRD
Method Name: __init__


Project Name: masa-su/pixyz
Commit Name: 7606e71b0781df931d9b4291022e2f695d23ea86
Time: 2019-05-11
Author: masa@weblab.t.u-tokyo.ac.jp
File Name: pixyz/flows/operations.py
Class Name: ShuffleLayer
Method Name: __init__


Project Name: GPflow/GPflow
Commit Name: d47446fc6341f0b99373eed2ba252e321d6c1a1a
Time: 2020-03-23
Author: st--@users.noreply.github.com
File Name: gpflow/models/gplvm.py
Class Name: BayesianGPLVM
Method Name: __init__