Creating Maps in WKT format for DTN – ONE Simulator

We have to follow these steps to create map files in WKT format which has to be given as input for MapBasedMovement Models such as Shortest Path Map Based Movement , Working day Movement Model etc..

Click on images to see the zoomed version.

Step 1: Go to http://www.openstreetmap.org/ and select the coordinates of the area you want. Then choose export . It will give some file in .osm format like map.osm.

openstreetmap1

Step 2: Now we have to convert the map.osm file to map.wkt file. Use osm2wkt jar for that purpose. Download that jar file from http://www.tm.kit.edu/~mayer/osm2wkt/.

Step 3: Now use the following commands to convert .osm files to .wkt files.

java -jar osm2wkt.jar map.osm

osm2wkt

Step 4: We can extract the specific linesegments and points from the map we are  having. To generate that, we have to use another simulator “OPEN JUMP”.

Step 5: Download Openjump from the following link:  http://sourceforge.net/projects/jump-pilot/files/OpenJUMP/1.8.0/OpenJUMP-Installer-1.8.0-r4164-CORE.jar/download. Start the OPEN JUMP Simulator.

openjump_start

Step 6: Then open the map.osm file in Open Jump. Select the portion of the map from which you want to extract points.

opening_osm

Step 7: Go to Tools -> Edit Geometry -> Extract Points. After that it will extract all the points in the map and we can save the resultset as a WKT file.

extractpoints

Step 8: For Working Day Movement Model, we have to generate separate map files for Home Activity, Office Activity, Evening Activity Models and that map files should contain POINTS only. For MapBased Movement and Bus Movement, the WKT files should contain only LINESTRINGS.

References:

(1) http://www.tm.kit.edu/~mayer/osm2wkt/

(2) https://www.openstreetmap.org

(3)http://openjump.org/

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s