code: def _get_rotatable_bonds(mol: RDKitMol) -> List[Tuple[int, int]]:
      """
      https://github.com/rdkit/rdkit/blob/f4529c910e546af590c56eba01f96e9015c269a6/Code/GraphMol/Descriptors/Lipinski.cpp#L107
  
      Taken from rdkit source to find which bonds are rotatable store
      rotatable bonds in (from_atom, to_atom)
  
      Parameters
      ----------
      mol: rdkit.Chem.rdchem.Mol
          Ligand molecule
  
      Returns
      -------
      rotatable_bonds: List[List[int, int]]
          List of rotatable bonds in molecule
  
      Notes
      -----
      This function requires RDKit to be installed.
      """
      try:
          from rdkit import Chem
          from rdkit.Chem import rdmolops
      except ModuleNotFoundError:
          raise ImportError(
              "This function requires RDKit to be installed."
          )
  
      pattern = Chem.MolFromSmarts(
          "[!$(*#*)&!D1&!$(C(F)(F)F)&!$(C(Cl)(Cl)Cl)&!$(C(Br)(Br)Br)&!$(C([CH3])("
          "[CH3])[CH3])&!$([CD3](=[N,O,S])-!@[#7,O,S!D1])&!$([#7,O,S!D1]-!@[CD3]="
          "[N,O,S])&!$([CD3](=[N+])-!@[#7!D1])&!$([#7!D1]-!@[CD3]=[N+])]-!@[!$(*#"
          "*)&!D1&!$(C(F)(F)F)&!$(C(Cl)(Cl)Cl)&!$(C(Br)(Br)Br)&!$(C([CH3])([CH3])"
          "[CH3])]"
      )
      rdmolops.FastFindRings(mol)
      rotatable_bonds = mol.GetSubstructMatches(pattern)
      return rotatable_bonds
  
file_path: deepchem/deepchem/utils/pdbqt_utils.py
imports: from typing import Dict, List, Optional, Set, Tuple
  from deepchem.utils.typing import RDKitMol
label_desc: Use image node_id 4 for calling a global function with example usage: _get_rotatable_bonds(mol) and returns: rotatable_bonds