示例#1
0
    def get_kpoints(self, structure):
        """
        Get a KPOINTS file for NonSCF calculation.  kpoints are
        Gamma-centered mesh grid. 

        Args:
            structure (Structure/IStructure): structure to get Kpoints
        """
        kppa = self.kpoints_settings["kpoints_density"]
        kpoints = Kpoints.automatic_gamma_density(structure, kppa)

        return kpoints
示例#2
0
 def get_kpoints(self, structure):
     """
     Writes out a KPOINTS file using the automated gamma grid method.
     VASP crashes GW calculations on none gamma centered meshes.
     """
     if self.sort_structure:
         structure = structure.get_sorted_structure()
     dens = int(self.kpoints_settings['grid_density'])
     if dens == 1:
         return Kpoints.gamma_automatic()
     else:
         return Kpoints.automatic_gamma_density(structure, dens)
示例#3
0
 def get_kpoints(self, structure):
     """
     Writes out a KPOINTS file using the automated gamma grid method.
     VASP crashes GW calculations on none gamma centered meshes.
     """
     if self.sort_structure:
         structure = structure.get_sorted_structure()
     dens = int(self.kpoints_settings['grid_density'])
     if dens == 1:
         return Kpoints.gamma_automatic()
     else:
         return Kpoints.automatic_gamma_density(structure, dens)