code: def get_mol_subset(
      coords: np.ndarray,
      mol: Union[RDKitMol, MolecularFragment],
      atom_indices_to_keep: List[int],
  ) -> Tuple[np.ndarray, MolecularFragment]:
      """Strip a subset of the atoms in this molecule
  
      Parameters
      ----------
      coords: np.ndarray
          Must be of shape (N, 3) and correspond to coordinates of mol.
      mol: rdkit.Chem.rdchem.Mol or MolecularFragment
          The molecule to strip
      atom_indices_to_keep: list
          List of the indices of the atoms to keep. Each index is a unique
          number between `[0, N)`.
  
      Returns
      -------
      Tuple[np.ndarray, MolecularFragment]
          A tuple of `(coords, mol_frag)` where `coords` is a numpy array of
          coordinates with hydrogen coordinates. `mol_frag` is a `MolecularFragment`.
  
      Notes
      -----
      This function requires RDKit to be installed.
      """
      try:
          from rdkit import Chem
      except ModuleNotFoundError:
          raise ImportError(
              "This function requires RDKit to be installed."
          )
  
      indexes_to_keep = []
      atoms_to_keep = []
      # Compute partial charges on molecule if RDKit Mol
      if isinstance(mol, Chem.Mol):
          compute_charges(mol)
      atoms = list(mol.GetAtoms())
      for index in atom_indices_to_keep:
          indexes_to_keep.append(index)
          atoms_to_keep.append(atoms[index])
      coords = coords[indexes_to_keep]
      mol_frag = MolecularFragment(atoms_to_keep, coords)
      return coords, mol_frag
  
imports: import itertools
  import numpy
  from typing import List, Optional, Sequence, Set, Tuple, Union
  import logging
  from deepchem.utils.typing import RDKitAtom, RDKitMol
  from deepchem.utils.geometry_utils import compute_pairwise_distances
label_desc: Use image node_id 3 for calling a global function with example usage: get_mol_subset(coords, mol, atom_indices_to_keep) and returns: coords,  mol_frag