phonopy command#
The phonopy command runs the phonon calculation step of the workflow. It
reads a phonopy.yaml-like file (phonopy-yaml format), constructs the
phonon, and emits the requested property (band structure, mesh sampling, DOS,
thermal properties, group velocity, …).
To prepare displacements and to convert calculator results into the phonopy
input format (FORCE_SETS, FORCE_CONSTANTS) use phonopy-init command.
Example#
In the NaCl example for the VASP calculator,
% phonopy-init -d --dim 2 2 2 --pa auto -c POSCAR-unitcell
% phonopy-init --sp -f vasprun.xml-00{1,2}
In the NaCl-qe example for the QE calculator,
% phonopy-init --qe -d --dim 2 2 2 --pa auto -c NaCl.in
% phonopy-init --sp -f NaCl-00{1,2}.out
The first and second commands create phonopy_disp.yaml and
phonopy_params.yaml, respectively.
Once the phonopy_xxx.yaml file is available, the phonon calculation is run as
the post-process:
% phonopy --band auto -p phonopy_params.yaml
phonopy can read files with the following extensions: xz, lzma, gz, and
bz2. Therefore when the file size of phonopy_params.yaml is large, it is
recommended to compress it.
% xz phonopy_params.yaml
% phonopy --band auto -p phonopy_params.yaml.xz
Behaviour#
phonopy_xxx.yaml-like file (phonopy-yaml format) is always required, provided in either of two ways:phonopy_xxx.yaml-like file is given as the first argument of the command.phonopy_disp.yamlorphonopy.yamlis placed in the current directory. The search preference isphonopy_disp.yaml>phonopy.yaml.
The
-coption (read crystal structure separately) does not exist — the crystal structure is read from the yaml file.Use of command options is recommended, but a phonopy configuration file (Configuration file) can be read through
--configoption.If parameters for non-analytical term correction (NAC) are found, NAC is automatically enabled. This can be disabled by
--nonacoption.When force constants are calculated from displacements and forces dataset, force constants are automatically symmetrized. From phonopy v2.30.0,
symfcis used for the symmetrization. From phonopy v2.41.0, symfc-projector is used to symmetrize force constants calculated by the finite difference approach. The old behavior of the symmetrization can be performed by--fc-calculator traditionaloption. The--no-sym-fcoption can be used to calculate force constants in the traditional force constants calculator without symmetrization.
Relation to phonopy-load#
phonopy-load is the historical name of this command and is kept as a
deprecated alias. It emits a warning and otherwise behaves identically to
phonopy. Use phonopy in new scripts.