forked from wannier-utils-dev/cif2qewan
-
Notifications
You must be signed in to change notification settings - Fork 0
/
submit_all.sh
executable file
·39 lines (30 loc) · 1.03 KB
/
submit_all.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/bin/bash
MPI_PREFIX="mpirun -n 16"
ESPRESSO_DIR=/path/to/espresso_dir
WANNIER90_DIR=/path/to/wannier90_dir
CIF2QEWAN_DIR=/path/to/cif2qewan_dir
TOML_FILE=/path/to/cif2qewan.toml
python $CIF2QEWAN_DIR/cif2qewan.py *.cif $TOML_FILE
$MPI_PREFIX $ESPRESSO_DIR/bin/pw.x < scf.in > scf.out
cp -r work check_wannier/
cp -r work band/
$MPI_PREFIX $ESPRESSO_DIR/bin/pw.x < nscf.in > nscf.out &&
$MPI_PREFIX $WANNIER90_DIR/wannier90.x -pp pwscf &&
$MPI_PREFIX $ESPRESSO_DIR/bin/pw2wannier90.x < pw2wan.in > pw2wan.out &&
rm -r work
# set dis_froz_max = EF+1eV
ef=$(grep Fermi nscf.out | cut -c27-35)
ef1=$(bc -l <<< "$ef + 1")
sed -i "s/dis_froz_max .*/dis_froz_max = $ef1/g" pwscf.win
$MPI_PREFIX $WANNIER90_DIR/wannier90.x pwscf
cd check_wannier &&
$MPI_PREFIX $ESPRESSO_DIR/bin/pw.x < nscf.in > nscf.out &&
rm -r work &&
cd ../
python $CIF2QEWAN_DIR/wannier_conv.py
cd band &&
$MPI_PREFIX $ESPRESSO_DIR/bin/pw.x < nscf.in > nscf.out &&
$MPI_PREFIX $ESPRESSO_DIR/bin/bands.x < band.in > band.out &&
rm -r work &&
cd ../
python $CIF2QEWAN_DIR/band_comp.py