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

cleanup

parent 38008fdc
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -14,6 +14,7 @@ from deepchem.utils.fragment_util import get_contact_atom_indices

logger = logging.getLogger(__name__)


def extract_active_site(protein_file, ligand_file, cutoff=4):
  """Extracts a box for the active site.

+1 −0
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ logger = logging.getLogger(__name__)

class PoseGenerator(object):
  """A Pose Generator computes low energy conformations for molecular complexes.

  Many questions in structural biophysics reduce to that of computing
  the binding free energy of molecular complexes. A key step towards
  computing the binding free energy of two complexes is to find low
+4 −0
Original line number Diff line number Diff line
@@ -120,6 +120,7 @@ def vina_hbond(d):
      np.where(d < 0, (1.0 / 0.7) * (0 - d), np.zeros_like(d)))
  return out_tensor


def vina_gaussian_first(d):
  """Computes Autodock Vina's first Gaussian interaction term.

@@ -139,6 +140,7 @@ def vina_gaussian_first(d):
  out_tensor = np.exp(-(d / 0.5)**2)
  return out_tensor


def vina_gaussian_second(d):
  """Computes Autodock Vina's second Gaussian interaction term.

@@ -158,6 +160,7 @@ def vina_gaussian_second(d):
  out_tensor = np.exp(-((d - 3) / 2)**2)
  return out_tensor


def weighted_linear_sum(w, x):
  """Computes weighted linear sum.

@@ -170,6 +173,7 @@ def weighted_linear_sum(w, x):
  """
  return np.sum(np.dot(w, x))


def vina_energy_term(coords1, coords2, weights, wrot, Nrot):
  """Computes the Vina Energy function for two molecular conformations