exit with -1 when error (for travis)
add function to return geometry