1
0
Fork 0

Add remaining WorldScenery processing scripts.

This commit is contained in:
Ralf Gerlich 2010-07-17 17:30:51 +02:00
parent dc039f503c
commit f68f25e0c5
6 changed files with 60 additions and 63 deletions

View file

@ -0,0 +1,13 @@
#! /bin/bash
# Previously Skipped: EBPP
# Manually removed: NZSP (led to a runway around the world)
# Fixed: YSAR (was marked as land airport, but was a heliport)
WORKDIR=$HOME/workdirs/world_scenery
#APTDAT="/home/martin/GIT/fgdata/Airports/apt.dat.gz"
#APTDAT="/home/rgerlich/rawdata/apt.dat.gz"
APTDAT="/home/rgerlich/rawdata/apt.helidat.gz"
SPAT="--nudge=20"
exec /usr/bin/time genapts --input=$APTDAT --work=$WORKDIR $SPAT > genapts.log 2>&1

View file

@ -0,0 +1,8 @@
#! /bin/bash
./start_construct_server.sh
# Start 4 clients
for f in 1 2; do
./start_construct_client.sh $f
done

8
src/Prep/DemChop/chopsrtm1.sh Executable file
View file

@ -0,0 +1,8 @@
#! /bin/bash
DATADIR=/home/martin/archive/GIS/GISData/SRTM/version2_1/HGT/SRTM1/
WORKDIR=$HOME/workdirs/world_scenery
for file in "$DATADIR/"Region_*/*.hgt.zip; do
hgtchop 1 $file $WORKDIR/SRTM2-America-1
done

13
src/Prep/DemChop/chopsrtm3.sh Executable file
View file

@ -0,0 +1,13 @@
#! /bin/bash
echo "Available regions: Africa Australia Eurasia Islands North_America South_America"
#DATADIR=/mnt/agami/custom_scenery/SRTM/version2/HGT
DARADIR=/home/martin/archive/GIS/GISData/SRTM/version2_1/HGT/SRTM3/
WORKDIR=$HOME/workdirs/world_scenery
for region in Africa Australia Eurasia Islands North_America South_America; do
for file in "$DATADIR/$region/"*.hgt.zip; do
hgtchop 3 $file $WORKDIR/SRTM2-$region-3
done
done

View file

@ -1,28 +1,7 @@
#!/bin/sh #! /bin/bash
#
TOOLPATH=`pwd` WORKDIR=$HOME/workdirs/world_scenery
SOURCE=/stage/fgfs01/curt/RawData/DEM-30-Ascii
SCRATCH=/tmp/Scratch
WORK=/stage/fgfs04/curt/Work/DEM-30-New
if [ -z $1 ]; then for f in $WORKDIR/SRTM-30-ASCII/*/*.dem; do
echo "usage: $0 base-dem-30-ascii-file" demchop $f $WORKDIR/SRTM-30
exit done
fi
if [ ! -d $SCRATCH ]; then
mkdir -p $SCRATCH
fi
cd ${SCRATCH} || exit
echo "cd to $SCRATCH successful"
tar xzvf ${SOURCE}/${1}.tar.gz
for i in ${SCRATCH}/$1/*.dem; do
${TOOLPATH}/demchop $i $WORK >> ${TOOLPATH}/log-$1 2>&1
done
echo rm -rf ${SCRATCH}
rm -rf ${SCRATCH}

View file

@ -1,39 +1,15 @@
#!/bin/sh #! /bin/bash
#
TOOLPATH=`pwd`
SOURCE=/stage/fgfs01/curt/RawData/DEM-30-Bin
OUTPUTBASE=/stage/fgfs01/curt/RawData/DEM-30-Ascii
SCRATCH=${SOURCE}/Scratch
# clean the scratch space
echo rm -rf ${SCRATCH}/*
rm -rf ${SCRATCH}/*
cd ${SCRATCH} || exit
echo "cd to $SCRATCH successful"
tar xzvf ${SOURCE}/${1}.tar.gz
NAME=`echo *.DEM`
BASE=`basename $NAME .DEM`
LOWBASE=`echo $BASE | tr A-Z a-z`
OUTPUT=${OUTPUTBASE}/${LOWBASE}
echo mkdir -p $OUTPUT
mkdir -p $OUTPUT
${TOOLPATH}/raw2ascii ${SCRATCH}/${BASE} ${OUTPUT}
cd ${OUTPUTBASE} || exit
echo "cd to $OUTPUTBASE successful"
tar czvf ${LOWBASE}.tar.gz ${LOWBASE}
echo rm -rf ${LOWBASE}
rm -rf ${LOWBASE}
#DATADIR=/mnt/geothumper/data/custom_scenery/SRTM/srtm30/
DATADIR=/home/martin/archive/GIS/GISData/SRTM/version2_1/HGT/SRTM30
WORKDIR=$HOME/workdirs/world_scenery
for file in e020n90 e060n90 e100n90 e140n90 w020n90 w060n90 w100n90 w140n90 w180n90; do
unzip $DATADIR/$file/$file.dem.zip
unzip $DATADIR/$file/$file.hdr.zip
UPPERBASE=`echo $file | tr a-z A-Z`
OUTPUTDIR=$WORKDIR/SRTM-30-ASCII/$file
mkdir -p $OUTPUTDIR
raw2ascii $UPPERBASE $OUTPUTDIR
rm $UPPERBASE.{DEM,HDR}
done