class_docstr: Data structure that contains information about a contracted gaussian
  type orbital (CGTO).
  
  Examples
  --------
  >>> import torch
  >>> from deepchem.utils.dft_utils import CGTOBasis
  >>> alphas = torch.ones(1)
  >>> coeffs = torch.ones(1)
  >>> cgto = CGTOBasis(angmom=0, alphas=alphas, coeffs=coeffs)
  >>> cgto.wfnormalize_()
  CGTOBasis(angmom=0, alphas=tensor([1.]), coeffs=tensor([2.5265]), normalized=True)
docstr: Wavefunction normalization
  
  The normalization is obtained from CINTgto_norm from
  libcint/src/misc.c, or
  https://github.com/sunqm/libcint/blob/b8594f1d27c3dad9034984a2a5befb9d607d4932/src/misc.c#L80
  
  Please note that the square of normalized wavefunctions do not integrate
  to 1, but e.g. for s: 4*pi, p: (4*pi/3)
docstr_tok: ["Wavefunction","normalization","The","normalization","is","obtained","from","CINTgto_norm","from","libcint\/src\/misc.c",",","or","https",":","\/\/github.com\/sunqm\/libcint\/blob\/b8594f1d27c3dad9034984a2a5befb9d607d4932\/src\/misc.c","#","L80","Please","note","that","the","square","of","normalized","wavefunctions","do","not","integrate","to","1",",","but","e.g",".","for","s",":","4","*","pi",",","p",":","(","4","*","pi\/3",")"]
code: def wfnormalize_(self) -> "CGTOBasis":
      """Wavefunction normalization
  
      The normalization is obtained from CINTgto_norm from
      libcint/src/misc.c, or
      https://github.com/sunqm/libcint/blob/b8594f1d27c3dad9034984a2a5befb9d607d4932/src/misc.c#L80
  
      Please note that the square of normalized wavefunctions do not integrate
      to 1, but e.g. for s: 4*pi, p: (4*pi/3)
  
      """
  
      # if the basis has been normalized before, then do nothing
      if self.normalized:
          return self
  
      coeffs = self.coeffs
  
      # normalize to have individual gaussian integral to be 1 (if coeff is 1)
      value = gaussian_integral(2 * self.angmom + 2, 2 * self.alphas)
      assert isinstance(value, torch.Tensor)
      coeffs = coeffs / torch.sqrt(value)
  
      # normalize the coefficients in the basis (because some basis such as
      # def2-svp-jkfit is not normalized to have 1 in overlap)
      ee = self.alphas.unsqueeze(-1) + self.alphas.unsqueeze(
          -2
      )  # (ngauss, ngauss)
      ee = gaussian_integral(2 * self.angmom + 2, ee)  # type: ignore
      s1 = 1 / torch.sqrt(torch.einsum("a,ab,b", coeffs, ee, coeffs))
      coeffs = coeffs * s1
  
      self.coeffs = coeffs
      self.normalized = True
      return self
  
imports: from typing import Union, TypeVar, Generic, Optional, Callable, List, Dict
  from dataclasses import dataclass
  import torch
  import numpy
  from deepchem.utils import gaussian_integral
label_desc: Use image node_id 3 for calling the CGTOBasis obj's underlying member method code with example usage: obj.wfnormalize_() and returns: self, self