This repository is for the map data and walking instructions for the gophermaps project.
A critical part of our backend is a neo4j graph database representing the layout of the buildings and the tunnels & skyways connecting them. In order to generate this database, we first have to map out these tunnels and skyways. We'll be using JOSM to do this.
-
Clone the repository. It contains the data we'll be editing and a reference image for the gopher way from PTS
-
Install JOSM
-
Launch JOSM. You'll see this screen:
- Click the blue folder icon and open the
map.osm
file from the repository
- When the data loads, you'll see something like this- some nodes and lines on a black background:
- Open the JOSM Settings panel. On macOS, you open it like you do for any other app-
- Click the blue puzzle-piece icon to view the plugin settings
- Search for the PicLayer extension and check the box to download it
-
Click "OK" to close the preferences panel
-
Now that we have PicLayer installed, you'll see the "New picture layer from file..." option in the Imagery menu
- Select the
pts-gw-map.png
image file. It should automatically load the corresponding calibration file to align the image layer with the map data.
You're now ready to begin mapping. The plugin woill remain installed, but you may need to reload the image layer from the Imagery menu the next time you run JOSM
Tip
If you're finding it difficult to see the map data with the image layer behind it, you can adjust its opacity by clicking button with the icon of an eye with a gradient underneath it in the layers panel on the top-right of the screen.
The core components of the OSM data is nodes and "ways". Nodes are the little squares you see on the map, and ways are the lines connecting. Both nodes and ways can be given tags, as shown by the contents of the "tags/memberships" panel when they're selected.
These tags play a vital role in making this project "work", so it is crucial that we all follow the same standards for tagging. Before I go over the style guide, however, I'll show you how to create nodes and ways.
Note
For this section, I'll have the opacity of the image layer reduced so that the map data can be more easily discerned
First, make sure that the map data layer is selected. You'll know it's selected if there's a green check mark next to the map.osm
layer in the Layers panel.
Your mode/tool selection can be found on the left edge of the window. Tooltips are available if you hover your mouse, and the functionality is rather self-explanatory
For now, select the "Draw Nodes" tool.
- Clicking on the map when in this mode will create a node, and clicking again will create another node and automatically connect them with a way
- If you just want to create a single node, hitting the Escape key will finish the operation
We want a node on each of the "dots" on the reference image, and for the ways to match the lines on the image. For the tunnels that aren't straight lines, simply use multiple nodes. Alternatively, you can draw a straight line from the start to the end, switch to the move/select mode, and click the + in the middle of the line to bisect it with a new node, and move it into place.
When you're done working, save the map.osm file and commit your changes to the git repository. JOSM will ask you if you want to upload the changes. DO NOT DO SO.
- Every Gopher Way entrance in each building (the white circles on the PTS map) should have a node
- Each entrance node should be connected to each entrance node in the same building. This is how we will index and provide instructions on moving within buildings to the different tunnels The following image shows what a mapped building should look like:
OSM tags are stored as key:value pairs. They are case-sensitive.
Building Entrance Nodes should have the following tags:
- "building" with the name of the building as the value
- "floor" with the floor number the tunnel entrance is on. Alphabetic floors "e.g. G, B, SB" should be capitalized
Ways connecting Building Entrance Nodes in the same building should have the following tags:
- "type" with the value "inter-building"
Ways connecting different buildings should have the following tags:
- "type" with the value "tunnel" or "skyway" depending on the type of the connection
TBD.