combined fortfile creation and interpolation fix into meta script

This commit is contained in:
caes 2016-06-10 02:28:20 -04:00
parent 84c621f35e
commit 7f4bc149e3
2 changed files with 17 additions and 4 deletions

View File

@ -3,7 +3,7 @@
script_dir=$( cd $(dirname $0) ; pwd -P |sed 's@^\(.*\)/scripts.*@\1/scripts@')
basedir=`pwd`
if [[ -x $script_dir/../bin/interpolate_fix]];
if [[ -x $script_dir/../bin/interpolation_fix ]]
then
echo "Binary available. Proceeding."
else
@ -11,15 +11,16 @@ else
exit 9
fi
#for fortfile in $(echo fort.*);
for fortfile in $@
do
if [[ -e $(basename $fortfile) ]]
then
mkdir -p uninterpolated
mv $fortfile uninterpolated
echo $script_dir/../bin/interpolate_fix uninterpolated/$(basename $fortfile) $fortfile
$script_dir/../bin/interpolation_fix uninterpolated/$(basename $fortfile) $fortfile
else
echo $script_dir/../bin/interpolate_fix $fortfile $(basename $fortfile)
$script_dir/../bin/interpolation_fix $fortfile $(basename $fortfile)
fi
echo ""
done
exit 0

View File

@ -0,0 +1,12 @@
#!/bin/bash
# This script not generalized. Use with caution.
mkdir fortfiles
cd fortfiles
../../../../../bin/create_fort_files ../mpi_grid.out ../../../../../reference/linelist
../../../../../scripts/meta/bulk_interpolation_fix.sh fort.* >> interpolation_report
tar cf ../fortfiles_4thdex_ngc5548_mehdipour_cldn24.tar fort.*
cd ..
gzip fortfiles_4thdex_ngc5548_mehdipour_cldn24.tar
echo done