0

I want to reduce the file size of some gpx files with gdal ogr2ogr.

When I use simplify like the following command in Mac Terminal the file size does not really shrink:

ogr2ogr -simplify 0.00001 output.gpx input.gpx

And when I do the following it gives me an error permission denied:

input.gpx do ogr2ogr -simplify 0.00001
3

1 Answer 1

0

I have now done it with GPSBabel

  • For one file:

gpsbabel -w -r -t -i gpx -f /Users/user/Downloads/gpx-files1/file.gpx -x simplify,count=100 -o gpx -F /Users/aronsommer/Downloads/gpx-files2/file.gpx

  • For multiple files:

for f in /Users/user/Downloads/gpx-files1/*.gpx; do /Applications/GPSBabelFE.app/Contents/MacOS/gpsbabel -w -r -t -i gpx -f $f -x simplify,count=100 -o gpx -F $f; done

  • If command not found: gpsbabel

Use /Applications/GPSBabelFE.app/Contents/MacOS/gpsbabel

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.