Monday, May 7, 2007

[slightly off topic] Google Maps of Boulder Bike Paths

This is not Smallworld-related but is of interest to me. Every since I moved to Boulder (Colorado, USA) in March, I have been amazed by the number of bicycle paths in the city. Apparently the city will even plow the snow off the paths after a snow storm.

As a new resident of this fair city, I have often wondered how I can get to my destination using the available bike path network. The city provides some great paper and pdf network maps and even plans to create a bike-route-finding website (aka on-the-fly directions for cyclists) later this year. But I think there is still a need for integrating the network maps with a web search engine like Google Maps. Well, Google has recently implemented Google My Maps and I have started using that freely-available tool to start building an overlay on Google Map search results. You can read about it and see the current state of the project at the Cycling in Boulder blog.

If you are interested in contributing to the data in Boulder, please let me know. And if you are interested in doing something for a bike path network in your town that would be great, too! I have two ultimate goals:
  • get people onto their bikes
  • have a large enough interest in something like this that Google takes note and introduces searchable/traceable bike path networks into their Google Maps data.

Tuesday, May 1, 2007

Magik Dialog Designer

Under the heading of “cool and useful Magik stuff”…


I recently had the opportunity to meet with a friend of mine who showed me his latest creation -- Dialog Designer



It is a tool that allows you to graphically layout your new Magik GUI with many of the commonly-used widgets, menubar, statusbar, and docks. Once you have layed out the GUI graphically and applied appropriate properties to the components, the Dialog Designer will stub out all the required Magik files, classes, methods, shared constants and XML config/gui files and place them in a new module directory structure.


While it will not write the Magik behaviour behind the widgets – you still need to write Magik code that does something when the button is clicked – it goes a very long way to building your :build_gui() method for you. And the nice thing is that tricky tasks like resizing rowcols or other widgets is now done automatically for you.


As a long-time Magik developer, I have never been too excited about GUI design because it can be a bit complicated (and time consuming) in Magik. Using the Dialog Designer will make the GUI design considerably easier and definitely save you a number of hours per GUI in development time.


The company that my friend works for has said that they will release the Dialog Designer to the SourceForge MagikComponents community. Until they have done that, I will keep the name of the developer and his company to myself. Stay tuned for a press release from them (hopefully soon) announcing the availability of this very cool and useful tool for Magik developers.

Tuesday, April 17, 2007

Using FME to report lines lengths per grid

I recently received a request from a reader asking me to give some more detail about how I accomplished the grid/valve KML report in "FME as a Spatial Intelligence tool for Smallworld". He wanted to do a slightly different report that summarized length of lines per grid.

Instead of explaining how I did that original report, I tried to see for myself if what he was asking was in itself an easy query in FME. I created a similar report using FME Workbench. You can see the FMW file here.

In less than an hour I was able to take as input Smallworld area and line features, and then compute the total length of all lines for a given area and then create both a CSV and KML report. CSV is a good and simple tabular report format. KML provides a nice visual representation that anyone using Google Earth can use to see your query results.

If you have FME Workbench, you can open the report_pipe_lengths_by_grid.fmw file and view the comments I put in there describing how the data/transformer flows work. If you do not have FME, you can download a fully functional trial version from http://www.safe.com.

The basic steps included:
  • read area and line feature sets from Smallworld into FME Workbench
  • use the LineOnAreaOverlayer transformer to split the line features at the area boundaries
  • use the LengthCalculator transformer to calculate the length of each line feature inside a given area boundary
  • use the Aggregator transformer to sum up the length of all lines per area feature
  • use the FeatureMerger transformer to assign the aggregate line length to each area feature
  • write results out to a KML file (click here for image of result)
  • write results out to a CSV file (click here for file)
The steps were fairly easy and demonstrate again the power of the FME tool for reporting and data manipulation applications.

[Shameless commercial plug: if you would like to explore how you could use FME to get meaningful reports out of your data, please contact me at the e-mail addresses listed on the "Contact Information" in the side bar of this blog]