Commit b09ee6ad authored by Bharath Ramsundar's avatar Bharath Ramsundar
Browse files

yapf

parent 715cb435
Loading
Loading
Loading
Loading
+9 −7
Original line number Diff line number Diff line
@@ -106,8 +106,10 @@ class TestAtomicConv(unittest.TestCase):
  def test_atomic_conv_with_feat(self):
    """A simple test for running an atomic convolution on featurized data."""
    dir_path = os.path.dirname(os.path.realpath(__file__))
    ligand_file = os.path.join(dir_path, "../../../feat/tests/data/3zso_ligand_hyd.pdb")
    protein_file = os.path.join(dir_path, "../../../feat/tests/data/3zso_protein.pdb")
    ligand_file = os.path.join(dir_path,
                               "../../../feat/tests/data/3zso_ligand_hyd.pdb")
    protein_file = os.path.join(dir_path,
                                "../../../feat/tests/data/3zso_protein.pdb")
    # Pulled from PDB files. For larger datasets with more PDBs, would use
    # max num atoms instead of exact.
    frag1_num_atoms = 44  # for ligand atoms
@@ -121,8 +123,8 @@ class TestAtomicConv(unittest.TestCase):
        neighbor_cutoff)
    # arbitrary label
    labels = np.array([0])
    features, _ = complex_featurizer.featurize_complexes(
         [ligand_file], [protein_file])
    features, _ = complex_featurizer.featurize_complexes([ligand_file],
                                                         [protein_file])
    dataset = deepchem.data.DiskDataset.from_numpy(features, labels)

    batch_size = 1
+4 −1
Original line number Diff line number Diff line
@@ -211,7 +211,10 @@ def load_pdbbind(featurizer="grid", split="random", subset="core", reload=True):
  if featurizer == "grid":
    featurizer = rgf.RdkitGridFeaturizer(
        voxel_width=2.0,
        feature_types=['ecfp', 'splif', 'hbond', 'salt_bridge', 'pi_stack', 'cation_pi', 'charge'],
        feature_types=[
            'ecfp', 'splif', 'hbond', 'salt_bridge', 'pi_stack', 'cation_pi',
            'charge'
        ],
        flatten=True)
  elif featurizer == "atomic":
    # Pulled from PDB files. For larger datasets with more PDBs, would use