Exemple #1
0
# fc_calc    = 'alm'
fc_calc = None
#
# g_max = 5.5
# g_min = -12.4
g_max = None
g_min = None
# f_max = 5.5
# f_min = -0.25
f_max = None
f_min = None

if nac:
    from phonopy.interface.vasp import get_born_vasprunxml
    born_chg, eps, _ = get_born_vasprunxml(
        is_symmetry=False,
        symmetrize_tensors=True,
    )
    from phonopy.interface.calculator import get_default_physical_units
    nac_factor = get_default_physical_units('vasp')['nac_factor']
    nac_params = {
        'born': born_chg,
        'dielectric': eps,
        'factor': nac_factor,
        # 'method':'wang',
    }
else:
    nac_params = None

from os import environ
environ['CUDA_VISIBLE_DEVICES'] = ''
from phonopy.interface import vasp
Exemple #2
0
 def set_nac_params_from_vasprun(self, vasprun_name: str) -> None:
     born, epsilon, _, = get_born_vasprunxml(
         vasprun_name,
         primitive_matrix=np.eye(3),
         supercell_matrix=self.supercell_matrix)
     self.nac_params = {"born": born, "dielectric": epsilon}