Commit ff50a3f5 authored by Matija Obreza's avatar Matija Obreza
Browse files

README updated

parent 6cd9012d
Geo Tools
Executing the default main class without additional arguments renders the program
$ java -jar genesys-geo-tools-0.1-SNAPSHOT.jar
Usage: java -Djava.awt.headless=true -jar geo-tools.jar country|landorsea [options] <inputFile> <outputFile>
<inputFile> File name or - to read CSV from STDIN
<outputFile> File name or - to write CSV to STDOUT
-v Increase log level.
-v Increase log level.
-csv ',"\' Set input CSV separator, quote and escape chars
The program writes log messages to STDERR.
## Running LandOrSea ##
Obtain the genesys-geo-tools-0.1-SNAPSHOT.jar file from the Downloads section or build from source code.
Prepare a CSV file with columns `DECLATITUDE`, `DECLONGITUDE`. The
program will test the geographic coordinates against the oceans and water data
and report the result in the column `LANDorSEA_check`.
### Obtaining base data
Download the two "large split polygons" shapefiles in WGS84 projection from:
......@@ -21,17 +41,26 @@ as the jar file of this application. You should now have three files in this dir
### Running the program
JAI library creates an AWT window. Run in headless mode:
JAI library creates an AWT window. Run the *Land or Sea* test in headless mode:
java -Djava.awt.headless=true -jar genesys-geo-tools-0.1-SNAPSHOT.jar
java -Djava.awt.headless=true -jar geo-tools.jar landorsea [options] <inputFile> <outputFile>
## Validating Country of Origin ##
Prepare a CSV file with columns `DECLATITUDE`, `DECLONGITUDE`. The
program will test the geographic coordinates against the country borders and
report the country ISO3 code in `ORIGCTY_check`.
When the input CSV includes `ORIGCTY`, the program will validate the reported
country against the one identified and report **OK** when they match.
### Country borders
Download two distinct shapefiles with country borders:
......@@ -44,13 +73,15 @@ Unpack the zip archives and drop the data into the `data/` folder. The applicati
The `TM_WORLD_BORDERS` data is used for initial matching. Any mismatch will then be looked up in the
very detailed `GADM0` and `GADM1` layers.
### Running the program
java -Djava.awt.headless=true -jar geo-tools.jar country [options] <inputFile> <outputFile>
## Features ##
* Accepts CSV as input, produces CSV output
## TODO List ##
* Generate HTML report
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment