class_docstr: Calculate the eigenvalues of Coulomb matrices for molecules.
  
  This featurizer computes the eigenvalues of the Coulomb matrices for provided
  molecules. Coulomb matrices are described in [1]_.
  
  Examples
  --------
  >>> import deepchem as dc
  >>> featurizers = dc.feat.CoulombMatrixEig(max_atoms=23)
  >>> input_file = 'deepchem/feat/tests/data/water.sdf' # really backed by water.sdf.csv
  >>> tasks = ["atomization_energy"]
  >>> loader = dc.data.SDFLoader(tasks, featurizer=featurizers)
  >>> dataset = loader.create_dataset(input_file)
  
  References
  ----------
  .. [1] Montavon, Grégoire, et al. "Learning invariant representations of
      molecules for atomization energy prediction." Advances in neural information
      processing systems. 2012.
docstr: Calculate eigenvalues of Coulomb matrix for molecules. Eigenvalues
  are returned sorted by absolute value in descending order and padded
  by max_atoms.
  
  Parameters
  ----------
  datapoint: rdkit.Chem.rdchem.Mol
      RDKit Mol object
  
  Returns
  -------
  np.ndarray
      The eigenvalues of Coulomb matrix for molecules.
      The default shape is `(num_confs, max_atoms)`.
      If num_confs == 1, the shape is `(max_atoms,)`.
docstr_tok: ["Calculate","eigenvalues","of","Coulomb","matrix","for","molecules",".","Eigenvalues","are","returned","sorted","by","absolute","value","in","descending","order","and","padded","by","max_atoms",".","Parameters","--","--","--","--","--","datapoint",":","rdkit.Chem.rdchem.Mol","RDKit","Mol","object","Returns","--","--","--","-","np.ndarray","The","eigenvalues","of","Coulomb","matrix","for","molecules",".","The","default","shape","is","`","(","num_confs",",","max_atoms",")","`",".","If","num_confs","==","1",",","the","shape","is","`","(","max_atoms",",",")","`","."]
code: def _featurize(self, datapoint: RDKitMol, **kwargs) -> np.ndarray:
      """
      Calculate eigenvalues of Coulomb matrix for molecules. Eigenvalues
      are returned sorted by absolute value in descending order and padded
      by max_atoms.
  
      Parameters
      ----------
      datapoint: rdkit.Chem.rdchem.Mol
          RDKit Mol object
  
      Returns
      -------
      np.ndarray
          The eigenvalues of Coulomb matrix for molecules.
          The default shape is `(num_confs, max_atoms)`.
          If num_confs == 1, the shape is `(max_atoms,)`.
  
      """
      if "mol" in kwargs:
          datapoint = kwargs.get("mol")
          raise DeprecationWarning(
              'Mol is being phased out as a parameter, please pass "datapoint" instead.'
          )
  
      cmat = self.coulomb_matrix(datapoint)
      features_list = []
      for f in cmat:
          w, v = np.linalg.eig(f)
          w_abs = np.abs(w)
          sortidx = np.argsort(w_abs)
          sortidx = sortidx[::-1]
          w = w[sortidx]
          f = pad_array(w, self.max_atoms)
          features_list.append(f)
      features = np.asarray(features_list)
      if features.shape[0] == 1:
          # `(1, max_atoms)` -> `(max_atoms,)`
          features = np.squeeze(features, axis=0)
      return features
  
file_path: deepchem/deepchem/feat/molecule_featurizers/coulomb_matrices.py
imports: import numpy
  from typing import Any, List, Optional
  from deepchem.utils.typing import RDKitMol
  from deepchem.utils.data_utils import pad_array
  from deepchem.feat.base_classes import MolecularFeaturizer
label_desc: Use image node_id 2 for calling the CoulombMatrixEig obj's underlying member method code with example usage: obj._featurize(datapoint) and returns: features