Using Google Earth with TS/PP-Draft

Questions and discussions about operating Tru-Traffic

Moderator: bullock

Using Google Earth with TS/PP-Draft

Postby bullock » Wed Mar 11, 2009 7:35 pm

A user recently emailed the following question:

Greg:

So what exactly does TSPPD 8 do with Google Earth? Can it produce a KML file that overlays on the Google Earth network? Does that mean I don't have to go into Google Earth and "trace" all of the roads in our Congestion Study beforehand?

Great advancement, if it does what I'm interpreting this correctly.

Thanks,


Expecting that others may have similar questions, I'll post the reply here. There are a number of ways even the free version of Google Earth helps with TS/PP-Draft 8.0. First let's review how to share information with Google Earth, then we'll discuss what you can do by sharing the information.

Transfer Intersection Locations to Google Earth:
  1. Google KML File. Use File: Save As... and change the file type to Google KML. In Google Earth, select My Places so it acts as as the root folder, then import using File: Open. You may export either a GPS Exchange Format (GPX) or a KML file.
  2. Windows Clipboard. Use Edit: Copy: Geographic Coordinates: Geographic Coordinates as Google KML). In Google Earth, select My Places so it acts as as the root folder, then paste using Ctrl-V, or right-click and choose Paste.
Either way, in Google Earth a new folder will appear called "<diagram data file name>.kml". When you double click on that folder, the map view will zoom in on the network.


Transfer Intersection Locations from Google Earth:
In collecting coordinates of intersections from Google Earth, you may either set placemarks at, or drag paths around, the intersections. Either way, it's best to create a folder in Google Earth where you store the set of placemarks or paths. Thereafter, you may select the folder to transfer its entire contents to TS/PP-Draft as follows
  1. Google KML File. Right-click on the folder and choose Save Place As... to save the folder to a KML File. In TS/PP-Draft, open the Intersection Parameters for any intersection, click the Coordinates button, then click the Import Coordinates icon in the list along the left edge to import the KML file.
  2. Windows Clipboard. Right-click on the folder and choose Copy. In TS/PP-Draft, use Edit: Paste or press Ctrl-V to paste the coordinates into the Network View, the Outline View, any diagram window, or the geographic coordinates window of any intersection.
Either way, when you either import or paste into TS/PP-Draft, TS/PP-Draft displays the entire list of coordinates along with their tentative intersection assignments. You may assign the unassigned coordinates to intersections, change the assignments, or skip coordinates (by not assigning them to any intersection) before clicking OK to accept the list. You can save yourself a step by making sure each intersection in TS/PP-Draft has a unique Intersection ID Number and assigning that Intersection ID Number directly to the placemark in Google Earth. To do this, in Google Earth add the ID number in the placemark's name or its description, preceded with either the text "ID:" or "#". Thereafter, TS/PP-Draft will tentatively assign those placemarks accordingly when you paste them from the clipboard or when you import the KML file.

If TS/PP-Draft already had some coordinates for some intersections, you have a choice whether you want the new coordinates from Google Earth to supplement (or merge with) the ones already in TS/PP-Draft or whether you want to replace the existing ones (overwriting them). If the folder in Google Earth has a complete set of coordinates for each intersection, then you probably want to replace the existing ones.


Transfer Trip Logs to Google Earth:
  1. Google KML File. In TS/PP-Draft, right-click on a Trip Log and choose Export Trip Log.... Change the file type to either Google KML or GPS Exchange Format (GPX). You probably want to prefer Google KML, as that will also assign icon colors to each trip log point based on its speed. For transferring to most other programs (other than Google Earth), you usually want to use GPS Exchange Format (GPX), as that includes a specification for transferring speed and heading, whereas Google KML does not have speed or heading in its specification (except by extension). In Google Earth, select My Places so it acts as as the root folder, then import using File: Open.
  2. Windows Clipboard. In TS/PP-Draft, right-click on a Trip Log and choose Copy: Copy as Google KML. In Google Earth, select My Places so it acts as as the root folder, then paste using Ctrl-V, or right-click and choose Paste.
Either way, in Google Earth a new folder will appear called "<diagram data file name>.kml" that has the Trip Log in it. When you double click on that Trip Log, the map view will zoom in on the trip log. You may use controls in Google Earth to specify how wide of a time slice to view. If you set wide enough, you'll see the entire trip log on the map. If you set it to a briefer time interval, then you may play the trip log in Google Earth as an animation. As the animation progresses, you'll see just the active points snaking along the arterial.


Transfer Trip Logs to TS/PP-Draft:
The trip log should be in a folder in Google Earth. Select the folder to transfer its entire contents to TS/PP-Draft as follows
  1. Google KML File. Right-click on the folder and choose Save Place As... to save the folder to a KML File. In TS/PP-Draft, right-click in the list of Trip Logs and choose Import Trip Log... to import the KML file.
  2. Windows Clipboard. Right-click on the folder and choose Copy. In TS/PP-Draft, open the list of Trip Logs and either press Ctrl-V or right click and choose Paste to paste the trip log.


Transfer Instantaneous Average of Trip Logs to Google Earth:
In TS/PP-Draft, make a Plot from Trip Logs, including all the Trip Logs you wish averaged together. Right-click on the Plot and choose Save: Save Instantaneous Average.... Change the file type to Google KML In Google Earth, select My Places so it acts as as the root folder, then import using File: Open.

Here are a few ways you can use these features.

Confirm or Correct Intersection Coordinates
  1. Follow the steps above to Transfer Intersection Locations from TS/PP-Draft to Google Earth.
  2. Double click on the new folder in Google Earth to zoom the map on the network.
  3. Scroll around the map and zoom as needed to ensure that each intersection has at least two placemarks straddling the center of the intersection. I like to put one placemark on, say, the NE corner of the intersection and one on the SW corner. The centroid (midpoint) of the two placemarks should be at the center of the intersection.
  4. If you find a placemark in the wrong location, right-click on it and choose Properties. While the Properties dialog is open, you may drag the placemark to the correct location.
  5. If you find an intersection with only one placemark, add a new one. To do this, I like to use a little trick to save a bit of time: First duplicate the existing placemark by right-clicking it and choosing Copy then pressing Ctrl-V. Then drag the newly pasted placemark to the correct location. As noted in the previous step, to drag it, you have to first right-click on it and choose Properties. The advantage of making the second placemark by duplicating the first is that if the first one already has an Intersection ID Number (in its name or description), that Intersection ID Number gets copied to the duplicate, so when you paste everything back into TS/PP-Draft, it will automatically assign it to the correct intersection.
  6. If you find an intersection with no placemarks, add placemarks by clicking the Add Placemark button on the toolbar and dragging the new placemark to the correct location. You may want to insert the Intersection ID Number into the placemark name or description, following the format "ID:123" or "#123" so TS/PP-Draft will automatically assign it to the correct intersection when you transfer back to TS/PP-Draft.
  7. When you've finished, follow the steps above to Transfer Intersection Locations from Google Earth to TS/PP-Draft.


Collect Geographic Coordinates for Your Network
  1. In Google Earth, add a pair of placemarks for each intersection by clicking the Add Placemark button on the toolbar and dragging the new placemark to the correct location. You may want to insert the Intersection ID Number into the placemark name or description, following the format "ID:123" or "#123" so TS/PP-Draft will automatically assign it to the correct intersection when you transfer back to TS/PP-Draft. After adding the first placemark and assigning it the Intersection ID Number, duplicate it by right-clicking it and choosing Copy then pressing Ctrl-V. Then drag the newly pasted placemark to the correct location. I like to put one placemark on, say, the NE corner of the intersection and one on the SW corner. The centroid (midpoint) of the two placemarks should be at the center of the intersection. As noted previously, to drag it, you have to first right-click on it and choose Properties. By duplicating the first placemark to add the second, the Intersection ID Number gets copied to the duplicate, so when you paste into TS/PP-Draft, it will automatically assign it to the correct intersection.
  2. When you've finished, follow the steps above to Transfer Intersection Locations from Google Earth to TS/PP-Draft.


View Trip Logs or Play it Like a Movie
  1. Follow the steps above to Transfer a Trip Log from TS/PP-Draft to Google Earth. Use one of the KML options so the colors indicate the speeds.
  2. Double click on the new folder in Google Earth to zoom the map on the trip log.
  3. Find the Time Slider on the map in Google Earth. Use the controls there to set the current viewing start time and end time. The wider a time span you set, the more points from your trip log you'll see at any moment.
  4. Click the Play button on the Time Slider to watch the trip log like a movie.


View Map of Instantaneous Average Speed
  1. Follow the steps above to Transfer Instantaneous Average of Trip Logs from TS/PP-Draft to Google Earth.
  2. Double click on the new folder in Google Earth to zoom the map on the average of trip logs.
  3. Color-coded icons along the artery indicate the speeds.
  4. In View: Preferences: Google KML, you may specify the colors and their corresponding speed thresholds.
  5. Click on a point in Google Earth to see a description of the point, including the travel time, speed, and contributing trip logs.

Google Earth has many other features that you may want to explore. The ones discussed here are especially useful for helping in travel time and delay studies with TS/PP-Draft, and they should get you going.

Enjoy.
Greg
bullock
Site Admin
 
Posts: 218
Joined: Thu May 06, 2004 6:51 pm
Location: Pacific Grove, CA

Return to Program Operation

Who is online

Users browsing this forum: No registered users and 4 guests

cron