class_docstr: Manages placeholders associated with batch of graphs and their topology
docstr: Converts the current batch of WeaveMol into tensorflow feed_dict.
  
  Assigns the atom features and pair features to the
  placeholders tensors
  
  params
  ------
  batch : np.ndarray
    Array of WeaveMol
  
  returns
  -------
  feed_dict : dict
    Can be merged with other feed_dicts for input into tensorflow
docstr_tok: ["Converts","the","current","batch","of","WeaveMol","into","tensorflow","feed_dict",".","Assigns","the","atom","features","and","pair","features","to","the","placeholders","tensors","params","--","--","--","batch",":","np.ndarray","Array","of","WeaveMol","returns","--","--","--","-","feed_dict",":","dict","Can","be","merged","with","other","feed_dicts","for","input","into","tensorflow"]
code: def batch_to_feed_dict(self, batch):
      """Converts the current batch of WeaveMol into tensorflow feed_dict.
  
      Assigns the atom features and pair features to the
      placeholders tensors
  
      params
      ------
      batch : np.ndarray
        Array of WeaveMol
  
      returns
      -------
      feed_dict : dict
        Can be merged with other feed_dicts for input into tensorflow
      """
      # Extract atom numbers
      atom_feat = []
      pair_feat = []
      atom_mask = []
      pair_mask = []
      membership = []
      max_atoms = self.max_atoms
      for im, mol in enumerate(batch):
          n_atoms = mol.get_num_atoms()
          atom_feat.append(
              np.pad(
                  mol.get_atom_features(),
                  ((0, max_atoms - n_atoms), (0, 0)),
                  "constant",
              )
          )
          atom_mask.append(
              np.array(
                  [1] * n_atoms + [0] * (max_atoms - n_atoms),
                  dtype=float,
              )
          )
          pair_feat.append(
              np.pad(
                  mol.get_pair_features(),
                  (
                      (0, max_atoms - n_atoms),
                      (0, max_atoms - n_atoms),
                      (0, 0),
                  ),
                  "constant",
              )
          )
          pair_mask.append(
              np.array(
                  [[1] * n_atoms + [0] * (max_atoms - n_atoms)]
                  * n_atoms
                  + [[0] * max_atoms] * (max_atoms - n_atoms),
                  dtype=float,
              )
          )
          membership.extend([im] * n_atoms)
      atom_feat = np.stack(atom_feat)
      pair_feat = np.stack(pair_feat)
      atom_mask = np.stack(atom_mask)
      pair_mask = np.stack(pair_mask)
      membership = np.array(membership)
      # Generate dicts
      dict_DTNN = {
          self.atom_features_placeholder: atom_feat,
          self.pair_features_placeholder: pair_feat,
          self.atom_mask_placeholder: atom_mask,
          self.pair_mask_placeholder: pair_mask,
          self.membership_placeholder: membership,
      }
      return dict_DTNN
  
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import unicode_literals
  import warnings
  import numpy
  import tensorflow
  from deepchem.nn.copy import Input
  from deepchem.feat.mol_graphs import ConvMol
label_desc: Use image node_id 3 for calling the WeaveGraphTopology obj's underlying member method code with example usage: obj.batch_to_feed_dict(batch) and returns: dict_DTNN