jlmcgraw / aviationCharts

Prepare Aeronav charts (sectional, IFR low/high, WAC, TAC, heli etc) for use as a seamless mosaic of mbtiles
64 stars 33 forks source link

tile_charts does not take into account the options #7

Closed JanC closed 6 years ago

JanC commented 6 years ago

Hi, if I'm not mistaken, the tile_charts.sh ignores the options and tries to tile all the charts even if only some of them were processed:

 ./make_seamless_charts.sh -e -m  /home/jan/shared/Charts/ 10-12-2017

will (after a while) end up with the error

--------Tiling ENR_CL01------------
Zoom levels are 0,1,2,3,4,5,6,7,8,9
WARNING: Warped chart /media/sf_MYPASSPORT/Charts/5_warpedRasters/enroute/ENR_CL01.tif doesn't exist

because it's trying to tile ENR_CL01. If I understand the naming correctly, ENR_CL01 is the caribbean low enroute which was not processed.

A simple workaround would be to return with a warning instead of exiting the script to allow the rest of tiling to continue:

if [ ! -f "$warped_chart" ]; then
    echo "WARNING: Warped chart $warped_chart doesn't exist" >&2
    return 0
fi
jlmcgraw commented 6 years ago

You're right, those options aren't used in the tile_charts.sh script. I'll update the usage to make it clear

Part of the problem is that the enroute and Caribbean charts are provided separately by the FAA, and that the Caribbean ones have to be converted from PDF and then manual georeferencing added. So I handle them separately initially but then lump them together for tiling purposes. A workaround for now is to always do enroute and caribbean at the same time (-c -e)