Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions examples/01_bravais_lattice/01_fcc_Si/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee output

if [[ ! -f output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/01_bravais_lattice/02_hex_MoS2/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee output

if [[ ! -f output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/01_bravais_lattice/03_so_SnTe/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee output

if [[ ! -f output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
15 changes: 7 additions & 8 deletions examples/01_bravais_lattice/runall.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
#!/bin/bash

for ii in *
do
if [ -d $ii ];then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
for ii in *; do
if [ -d $ii ]; then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
done
17 changes: 8 additions & 9 deletions examples/02_scf/01_pw_Si2/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/02_scf/02_lcao_Si2/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/02_scf/03_lcao_Cu/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/02_scf/04_lcao_ZnO/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
15 changes: 7 additions & 8 deletions examples/02_scf/runall.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
#!/bin/bash

for ii in *
do
if [ -d $ii ];then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
for ii in *; do
if [ -d $ii ]; then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
done
17 changes: 8 additions & 9 deletions examples/03_spin_polarized/01_H_atom/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,12 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np 1 ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
fi
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/03_spin_polarized/02_Fe_FM/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/mulliken.txt ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/mulliken.txt ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
echo "job succeeded!"
exit 0
fi
17 changes: 8 additions & 9 deletions examples/03_spin_polarized/03_Fe_AFM/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/mulliken.txt ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/mulliken.txt ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
echo "job succeeded!"
exit 0
fi
15 changes: 7 additions & 8 deletions examples/03_spin_polarized/runall.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
#!/bin/bash

for ii in *
do
if [ -d $ii ];then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
for ii in *; do
if [ -d $ii ]; then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
done
17 changes: 8 additions & 9 deletions examples/04_noncollinear/01_Fe_noncollinear/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@ ABACUS_THREADS=$(awk -F "=" '$1=="ABACUS_THREADS"{print $2}' ../../SETENV)

OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | tee scf.output

if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/mulliken.txt ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/mulliken.txt ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
echo "job succeeded!"
exit 0
fi
15 changes: 7 additions & 8 deletions examples/04_noncollinear/runall.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
#!/bin/bash

for ii in *
do
if [ -d $ii ];then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
for ii in *; do
if [ -d $ii ]; then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
done
21 changes: 10 additions & 11 deletions examples/05_soc/01_pw_GaAs/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,15 @@ OMP_NUM_THREADS=${ABACUS_THREADS} mpirun -np ${ABACUS_NPROCS} ${ABACUS_PATH} | t

rm INPUT KPT

if [[ ! -f scf.output ]] ||
[[ ! -f nscf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/running_nscf.log ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"* ) ]] ||
[[ ! ( "$(tail -1 OUT.ABACUS/running_nscf.log)" == " Total Time :"* ) ]]
then
echo "job failed!"
exit 1
if [[ ! -f scf.output ]] ||
[[ ! -f nscf.output ]] ||
[[ ! -f OUT.ABACUS/running_scf.log ]] ||
[[ ! -f OUT.ABACUS/running_nscf.log ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_scf.log)" == " Total Time :"*) ]] ||
[[ ! ("$(tail -1 OUT.ABACUS/running_nscf.log)" == " Total Time :"*) ]]; then
echo "job failed!"
exit 1
else
echo "job succeeded!"
exit 0
echo "job succeeded!"
exit 0
fi
15 changes: 7 additions & 8 deletions examples/05_soc/runall.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
#!/bin/bash

for ii in *
do
if [ -d $ii ];then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
for ii in *; do
if [ -d $ii ]; then
cd ${ii}
echo "RUN: ${ii}"
bash run.sh
cd ..
fi
done
Loading
Loading