def __init__(self, ksl, gd, nvalence, setups, bd, dtype, world, kd, kptband_comm, timer, atomic_hamiltonian=None): WaveFunctions.__init__(self, gd, nvalence, setups, bd, dtype, world, kd, kptband_comm, timer) self.ksl = ksl self.S_qMM = None self.T_qMM = None self.P_aqMi = None if atomic_hamiltonian is None: if ksl.using_blacs: atomic_hamiltonian = 'distributed' else: atomic_hamiltonian = 'dense' if isinstance(atomic_hamiltonian, str): atomic_hamiltonian = get_atomic_hamiltonian(atomic_hamiltonian) self.atomic_hamiltonian = atomic_hamiltonian self.timer.start('TCI: Evaluate splines') self.tci = NewTCI(gd.cell_cv, gd.pbc_c, setups, kd.ibzk_qc, kd.gamma) self.timer.stop('TCI: Evaluate splines') self.basis_functions = BasisFunctions( gd, [setup.phit_j for setup in setups], kd, dtype=dtype, cut=True)
def __init__(self, ksl, gd, nvalence, setups, bd, dtype, world, kd, kptband_comm, timer, atomic_correction=None, collinear=True): WaveFunctions.__init__(self, gd, nvalence, setups, bd, dtype, collinear, world, kd, kptband_comm, timer) self.ksl = ksl self.S_qMM = None self.T_qMM = None self.P_aqMi = None self.debug_tci = False if atomic_correction is None: if ksl.using_blacs: atomic_correction = 'scipy' else: atomic_correction = 'dense' if isinstance(atomic_correction, str): atomic_correction = get_atomic_correction(atomic_correction) self.atomic_correction = atomic_correction #self.tci = NewTCI(gd.cell_cv, gd.pbc_c, setups, kd.ibzk_qc, kd.gamma) with self.timer('TCI: Evaluate splines'): self.tciexpansions = TCIExpansions.new_from_setups(setups) self.basis_functions = BasisFunctions(gd, [setup.phit_j for setup in setups], kd, dtype=dtype, cut=True)
def __init__(self, diagksl, orthoksl, initksl, *args, **kwargs): WaveFunctions.__init__(self, *args, **kwargs) self.diagksl = diagksl self.orthoksl = orthoksl self.initksl = initksl self.set_orthonormalized(False) self.overlap = Overlap(orthoksl, self.timer)
def __init__(self, diagksl, orthoksl, initksl, *args, **kwargs): WaveFunctions.__init__(self, *args, **kwargs) self.diagksl = diagksl self.orthoksl = orthoksl self.initksl = initksl self.set_orthonormalized(False) self.overlap = Overlap(orthoksl, self.timer)
def __init__(self, gd, bd, kd, setups, dtype): # override constructor assert kd.comm.size == 1 WaveFunctions.__init__(self, gd, 1, setups, bd, dtype, world, kd, None) self.kin = Laplace(gd, -0.5, dtype=dtype, allocate=False) self.diagksl = None self.orthoksl = BandLayouts(gd, bd, dtype) self.initksl = None self.overlap = None self.rank_a = None
def __init__(self, gd, bd, kd, setups, dtype): # override constructor assert kd.comm.size == 1 WaveFunctions.__init__(self, gd, 1, setups, bd, dtype, world, kd, None) self.kin = Laplace(gd, -0.5, dtype=dtype) self.diagksl = None self.orthoksl = BandLayouts(gd, bd, dtype) self.initksl = None self.overlap = None self.rank_a = None
def __init__(self, ksl, gd, nvalence, setups, bd, dtype, world, kd, timer=None): WaveFunctions.__init__(self, gd, nvalence, setups, bd, dtype, world, kd, timer) self.ksl = ksl self.S_qMM = None self.T_qMM = None self.P_aqMi = None self.timer.start('TCI: Evaluate splines') self.tci = NewTCI(gd.cell_cv, gd.pbc_c, setups, kd.ibzk_qc, kd.gamma) self.timer.stop('TCI: Evaluate splines') self.basis_functions = BasisFunctions(gd, [setup.phit_j for setup in setups], kd, cut=True)
def __init__(self, ksl, gd, nvalence, setups, bd, dtype, world, kd, timer=None): WaveFunctions.__init__(self, gd, nvalence, setups, bd, dtype, world, kd, timer) self.ksl = ksl self.S_qMM = None self.T_qMM = None self.P_aqMi = None self.timer.start('TCI: Evaluate splines') self.tci = NewTCI(gd.cell_cv, gd.pbc_c, setups, kd.ibzk_qc, kd.gamma) self.timer.stop('TCI: Evaluate splines') self.basis_functions = BasisFunctions(gd, [setup.phit_j for setup in setups], kd.comm, cut=True) if not kd.gamma: self.basis_functions.set_k_points(kd.ibzk_qc)
def __init__(self, parallel, initksl, reuse_wfs_method=None, **kwargs): WaveFunctions.__init__(self, **kwargs) self.scalapack_parameters = parallel self.initksl = initksl if reuse_wfs_method is None or reuse_wfs_method == 'keep': wfs_mover = NullWfsMover() elif hasattr(reuse_wfs_method, 'cut_wfs'): wfs_mover = reuse_wfs_method elif reuse_wfs_method == 'paw': wfs_mover = PseudoPartialWaveWfsMover() elif reuse_wfs_method == 'lcao': wfs_mover = LCAOWfsMover() else: raise ValueError( 'Strange way to reuse wfs: {}'.format(reuse_wfs_method)) self.wfs_mover = wfs_mover self.set_orthonormalized(False) self._work_matrix_nn = None # storage for H, S, ... self._work_array = None