From fa8d1eb87744c15a5dae652c7eaf9b5a8f896814 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 14 Aug 2024 16:42:12 +0800 Subject: [PATCH 1/2] add NSW check for AIMD --- .../outcar2xyz/multipleFrames-outcars2nep-exyz.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh b/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh index 76c2c18fb..bde9dbc72 100755 --- a/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh +++ b/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh @@ -34,8 +34,16 @@ converged_files=() non_converged_files=() for file in $(find "$read_dire" -name "OUTCAR"); do + NSW=$(grep "NSW" "$file" | awk '{print $3}') + + if [ "$NSW" -ne 0 ]; then + converged_files+=("$file") + continue + fi + NELM=$(grep "NELM" "$file" | awk '{print $3}' | tr -d ';') actual_steps=$(grep -c "Iteration" "$file") + if grep -q "aborting loop because EDIFF is reached" "$file"; then if [ "$actual_steps" -lt "$NELM" ]; then converged_files+=("$file") From 1b99ef977cda926dad65bb7f36f0b5ac1564d9ac Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 14 Aug 2024 16:44:30 +0800 Subject: [PATCH 2/2] Change keywords for NSW check --- tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh b/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh index bde9dbc72..1f1c6fca6 100755 --- a/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh +++ b/tools/vasp2xyz/outcar2xyz/multipleFrames-outcars2nep-exyz.sh @@ -34,7 +34,7 @@ converged_files=() non_converged_files=() for file in $(find "$read_dire" -name "OUTCAR"); do - NSW=$(grep "NSW" "$file" | awk '{print $3}') + NSW=$(grep "number of steps for IOM" "$file" | awk '{print $3}') if [ "$NSW" -ne 0 ]; then converged_files+=("$file")