Skip to content

Commit b19860b

Browse files
committed
Add qekdist.sh and qemerge.sh
1 parent b11c07e commit b19860b

File tree

2 files changed

+51
-0
lines changed

2 files changed

+51
-0
lines changed

qekdist.sh

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#!/bin/bash
2+
# This script will distribute kpoints list into sigma.inp and prepare the directories
3+
4+
ProtoDir="proto"
5+
LIBK="libK"
6+
JobStart=1
7+
JobEnd=4
8+
for ((ijob=${JobStart};ijob<=${JobEnd};ijob++))
9+
do
10+
DirName="K${ijob}"
11+
if [ -d ${DirName} ]; then
12+
echo "${DirName} exists! q: quit, d: delete ?"
13+
read DELflag
14+
if [ ${DELflag} == "d" ]; then
15+
echo "Remove ${DirName}"
16+
rm -rf ${DirName}
17+
else
18+
echo "Exit ..."
19+
exit 2
20+
fi
21+
fi
22+
cp -r ${ProtoDir} ${DirName}
23+
cd ${DirName}
24+
cp ../${LIBK}/KP${ijob} ./KP.q
25+
#sbatch subqe.sh
26+
cd ..
27+
done

qemerge.sh

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/bin/bash
2+
# This script will distribute kpoints list into sigma.inp and prepare the directories
3+
4+
ProtoDir="proto"
5+
LIBK="libK"
6+
WFNmergeDir="wfnmerge"
7+
JobStart=1
8+
JobEnd=4
9+
10+
if [ ! -d ${WFNmergeDir} ]; then
11+
mkdir ${WFNmergeDir}
12+
fi
13+
14+
for ((ijob=${JobStart};ijob<=${JobEnd};ijob++))
15+
do
16+
DirName="K${ijob}"
17+
if [ ! -d ${DirName} ]; then
18+
echo "${DirName} does not exist!"
19+
exit
20+
else
21+
ln -sf ../${DirName}/WFN.h5 ./${WFNmergeDir}/WFN.${ijob}.h5
22+
ln -sf ../${DirName}/vxc.h5 ./${WFNmergeDir}/vxc.${ijob}.h5
23+
fi
24+
done

0 commit comments

Comments
 (0)