README.md 1.65 KB
Newer Older
Matija Obreza's avatar
Matija Obreza committed
1
Geo Tools
Matija Obreza's avatar
Service  
Matija Obreza committed
2
=========
Matija Obreza's avatar
Matija Obreza committed
3

Matija Obreza's avatar
Matija Obreza committed
4
## Running LandOrSea ##
Matija Obreza's avatar
Matija Obreza committed
5

Matija Obreza's avatar
Matija Obreza committed
6
Obtain the genesys-geo-tools-0.1-SNAPSHOT.jar file from the Downloads section or build from source code.
Matija Obreza's avatar
Matija Obreza committed
7

Matija Obreza's avatar
Service  
Matija Obreza committed
8
Download the two "large split polygons" shapefiles in WGS84 projection from:
Matija Obreza's avatar
Matija Obreza committed
9

Matija Obreza's avatar
Service  
Matija Obreza committed
10
11
12
13
14
* http://openstreetmapdata.com/data/land-polygons
* http://openstreetmapdata.com/data/water-polygons

Shapefiles used in this application are derived from OSM data, © OpenStreetMap contributors.

Matija Obreza's avatar
Matija Obreza committed
15
Create a `data` subdirectory in the directory with the jar file.
16
Extract the shapefile zip archives and move their contents into the newly created `data/` directory. 
Matija Obreza's avatar
Service  
Matija Obreza committed
17
18
as the jar file of this application. You should now have three files in this directory: 

Matija Obreza's avatar
Matija Obreza committed
19
20
21
22
23
	$ find .
	data/land_polygons.shp
	data/land...
	data/water_polygons.shp
	data/water...
Matija Obreza's avatar
Service  
Matija Obreza committed
24
25
26
	landorsea.jar


Matija Obreza's avatar
CLI  
Matija Obreza committed
27
JAI library creates an AWT window. Run in headless mode:
Matija Obreza's avatar
Service  
Matija Obreza committed
28

Matija Obreza's avatar
Matija Obreza committed
29
	java -Djava.awt.headless=true -jar genesys-geo-tools-0.1-SNAPSHOT.jar
Matija Obreza's avatar
Service  
Matija Obreza committed
30
31

Test.
Matija Obreza's avatar
CLI  
Matija Obreza committed
32

Matija Obreza's avatar
Matija Obreza committed
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
## Validating Country of Origin ##

Download two distinct shapefiles with country borders: 

* http://thematicmapping.org/downloads/world_borders.php (TM_WORLD_BORDERS-0.3)
* http://gadm.org/version2 (six dissolved layers)

Unpack the zip archives and drop the data into the `data/` folder. The application will load
`TM_WORLD_BORDERS-0.3.shp` and `gadm28_adm0.shp` (the top-admin-level shapefile) and 
`gadm28_adm1.shp` (the 2nd-level admin regions shapefile).

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.



Matija Obreza's avatar
Matija Obreza committed
49
## Features ##
50
51
52
53

* Accepts CSV as input, produces CSV output


Matija Obreza's avatar
Matija Obreza committed
54
## TODO List ##
Matija Obreza's avatar
CLI  
Matija Obreza committed
55
56
57

* Generate HTML report
* For "Water" entries, report distance to closest land.