utilities
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revisionNext revisionBoth sides next revision | ||
utilities [2013/02/28 13:31] – created daniel | utilities [2013/08/29 11:14] – [potfit_setup] daniel | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | {{TOC_right}} | + | ~~NOTOC~~ |
- | The potfit/util directory contains a number of utility programs for the preparation of '' | + | ====== Utilities ====== |
+ | ---- | ||
+ | The potfit/util directory contains a number of utility programs for the preparation of //potfit// input files and the postprocessing of //potfit// output files. | ||
- | ;[[#force2poscar|force2poscar]] | + | [[#force2imd|force2imd]]\\ |
- | :Converts force files (IMD output) to vasp POSCAR files. | + | Convert a potfit |
- | ; | + | |
- | :Converts vasp output (POSCAR, OUTCAR) to reference | + | |
- | ; | + | |
- | :Converts various | + | |
- | ; | + | |
- | :List all configurations in a configuration | + | |
- | ; | + | |
- | :Creates a parameter file for '' | + | |
- | ; | + | |
- | :A series of awk scripts to handle various tasks with potential files, like combining, appending, creating from analytical functions, generating from scratch, plotting, | + | |
- | ; | + | |
- | :Performs gauge transformations of '' | + | |
- | === force2poscar | + | [[#force2poscar|force2poscar]]\\ |
+ | | ||
- | Converts force files produced by [http:// | + | [[# |
+ | | ||
- | Compilation: | + | [[# |
+ | | ||
- | Usage: | + | [[# |
- | force2poscar input.force | + | Plot an analytic potfit potential using gnuplot. |
+ | |||
+ | [[# | ||
+ | | ||
- | The information is always written to a file called | + | [[# |
+ | | ||
- | === vasp2force === | + | [[Utilities/ |
+ | A series of awk scripts to handle various tasks with potential files, like combining, appending, creating from analytical functions, generating from scratch, plotting, | ||
- | Converts [http:// | + | ---- |
- | Compilation: | ||
- | Usage: | + | ==== force2imd |
- | | + | |
- | Reads information from all OUTCAR files in the current directory. <OUTCAR files> is an optional list of files, if not given all files matching OUTCAR* will be scanned (it is possible to read gzipped files ending with .gz). | + | Converts a potfit configuration into an [[http://imd.itap.physik.uni-stuttgart.de/|IMD]] checkpoint |
- | An optional file can be specified, containing the energy of a single free atom calculated by [http://cms.mpi.univie.ac.at/vasp/ VASP] in a single line in the same order as in the OUTCAR | + | |
- | # Al Co Ni | + | < |
- | -0.000219 | + | usage: force2imd [-h] [-n NUMBER] filename |
- | Writes | + | Convert |
- | Options: | + | positional arguments: |
+ | filename | ||
- | < | + | optional arguments: |
- | :list of chemical species to use (e.g. " | + | -h, --help show this help message |
- | <tt>-e < | + | -n NUMBER, |
- | :Specify file to read single atom energies from; if not found, " | + | |
- | <tt>-f</ | + | </code> |
- | :Uses only final configuration of multiple ionic steps. | + | |
- | <tt>-l</ | + | |
- | :List all chemical species found in OUTCAR | + | |
- | <tt>-r</ | + | |
- | :Scan recursively for OUTCAR files in every subdirectory. | + | |
- | <tt>-s list</ | + | |
- | :List is a comma separated list of ionic steps to use, e.g. " | + | |
- | < | + | |
- | :Assign this weight to all configurations. | + | |
- | === pottrans === | + | The IMD checkpoint file is written to standard output. |
- | Converts betweeen various potential models. | + | ==== force2poscar |
- | Compilation: < | + | Convert a potfit configuration into a [[http:// |
- | Usage: | + | <code> |
- | | + | usage: force2poscar [-h] [-n NUMBER] filename |
- | required parameters in paramfile (here with example values) | + | Convert a potfit configuration into a VASP POSCAR file. |
- | < | + | positional arguments: |
- | ntypes | + | |
- | ncols 3 # number of output potentials | + | |
- | infile | + | |
- | outfile | + | |
- | nsteps | + | |
- | atomic_e-density_file | + | |
- | embedding_energy_file | + | |
- | core_potential_file | + | |
- | #optional | + | optional |
+ | -h, --help | ||
+ | -n NUMBER, --number NUMBER | ||
+ | number of the configuration to convert | ||
+ | </ | ||
- | reorder | + | The VASP POSCAR data is written to standard output. |
- | # ntypes parameters necessary | + | |
- | r_start | + | |
- | </ | + | |
- | in.pot is converted to out.pot. in.pot can be of IMD potential format 1 or 2, out.pot is of '' | + | ==== list_config |
- | To convert from '' | + | Prints a brief list of all configurations in a potfit |
- | === list_config | + | < |
+ | usage: | ||
- | Lists all configurations in a config file. | + | Prints a brief list of all configurations in a potfit |
- | Compilation: | + | positional arguments: |
+ | filename | ||
- | Usage: | + | optional arguments: |
- | list_config | + | -h, --help |
+ | </code> | ||
- | Scans a '' | + | Scans a //potfit// configuration file and lists all configurations found. |
+ | This includes the origin (if comment is found), the starting line, number of atoms and | ||
+ | weight of the configuration. | ||
- | === potfit_setup | + | ==== makeapot |
- | This utility generates a simple parameter file for '' | + | Generate analytic potential files for //potfit// from scratch. |
- | Usage: | + | < |
- | potfit_setup | + | usage: makeapot |
+ | [-f [FUNCTIONS [FUNCTIONS ...]]] | ||
- | < | + | Create an analytic |
- | :name of the configuration file | + | |
- | < | + | |
- | :name of the potential file (for analytic potentials this can easily be created with the < | + | |
- | < | + | |
- | :prefix for all files, overrides -c and -p | + | |
- | :the following files will be checked: < | + | |
- | === awk scripts === | + | optional arguments: |
+ | -h, --help | ||
+ | -n N number of atoms types, runs from 0 to N-1 | ||
+ | -co CUTOFF, --cutoff CUTOFF | ||
+ | cutoff radius | ||
+ | -g use global cutoff parameter | ||
+ | -r, --random | ||
+ | -i TYPE, --type TYPE interaction type, e.g. pair, eam, adp, ... | ||
+ | -l, --list | ||
+ | -cp | ||
+ | -f [FUNCTIONS [FUNCTIONS ...]] | ||
+ | name of potential functions, either name or i*name, | ||
+ | where i=1,2,3,... | ||
+ | </ | ||
- | The awk scripts are listed on a [[Utilities/ | ||
- | === potscale | + | ==== plotapot |
- | '''< | + | |
- | potscale performs gauge transformations on EAM potentials. | + | This utility plots an analytic potential with gnuplot. |
- | Compilation: | + | <code> |
+ | usage: plotapot [-h] [-f] [-p] [-s size] [-t terminal] | ||
+ | pot_file [pair_dist_file] | ||
- | Usage: | + | Plot an analytic potfit potential using gnuplot. |
- | | + | |
- | Required parameters in paramfile: | + | positional arguments: |
+ | pot_file | ||
+ | pair_dist_file | ||
- | < | + | optional arguments: |
- | ntypes # number of atom types (types vary in [0..ntypes-1]) | + | -h, --help show this help message and exit |
- | startpot # file name for starting potential (*) | + | |
- | endpot # file name for final potential | + | -p only create plots in png format but do not show them |
- | imdpot # file name prefix for imd potential | + | -s size |
- | plotfile # file name for plotting potential (*) | + | -t terminal |
- | plotpointfile # | + | in gnuplot |
+ | </ | ||
- | imdpotsteps # number of points | + | ==== potfit_setup |
- | dummy_r # Distance, where dummy_rho | + | |
+ | This utility generates a simple parameter file for // | ||
+ | |||
+ | < | ||
+ | usage: potfit_setup [-h] [-c config file] [-p potential file] [-s prefix] | ||
+ | |||
+ | Create a simple potfit parameter file from scratch. | ||
+ | |||
+ | optional arguments: | ||
+ | -h, --help | ||
+ | -c config file name of the potfit configuration file | ||
+ | -p potential file name of the potfit potential file | ||
+ | -s prefix | ||
+ | |||
+ | The prefix takes precedence over the -c and -p switches.If the < | ||
+ | and < | ||
+ | </ | ||
+ | |||
+ | If the config file is given via the -c or -s option, the number of atom | ||
+ | types is automatically determined and adjusted | ||
+ | ==== vasp2force | ||
+ | |||
+ | Converts [[http:// | ||
+ | |||
+ | < | ||
+ | usage: vasp2force [-h] [-c C] [-e E] [-f] [-l] [-r] [-s CONFIGS] [-w WEIGHT] | ||
+ | [files [files ...]] | ||
+ | |||
+ | Converts vasp output data into potfit reference configurations. | ||
+ | |||
+ | positional arguments: | ||
+ | files list of OUTCAR files (plain or gzipped) | ||
+ | |||
+ | optional arguments: | ||
+ | -h, --help | ||
+ | -c C list of chemical species to use, e.g. -c Mg=0,Zn=1 | ||
+ | -e E | ||
+ | -f, --final | ||
+ | -l, --list | ||
+ | -r, --recursive | ||
+ | -s CONFIGS, --configs CONFIGS | ||
+ | comma separated list of configurations to use | ||
+ | -w WEIGHT, --weight WEIGHT | ||
+ | set configuration weight for all configurations | ||
+ | </ | ||
+ | |||
+ | Reads information from all OUTCAR files in the current directory. <OUTCAR files> is an optional list of files, if not given all files matching OUTCAR* will be scanned | ||
+ | An optional file can be specified, containing the energy of a single free atom calculated by [[http:// | ||
- | #optional options | + | < |
- | dummy_rho # dummy value of rho at dummy_r | + | # Al Co Ni |
- | dummy_phi # vector (length ntypes) dummy values of phi_ii at dummy_r | + | -0.000219 -0.993872 -0.855835 |
- | </ | + | </ |
- | Prints the values of < | + | Writes a force file to be used as a //potfit// reference configuration to standard output. If no options are given, force data is generated from each ionic step. |
- | If dummy_phi is given, the potential is transformed so that < | ||
- | IMD potentials and potential plot files are also written. | + | ==== awk scripts |
+ | The awk scripts are listed on a [[utilities/ |