Thursday, June 2, 2011

shifting asphalt grit

I haven't had much homeostasis between events lately, what with a graduation weekend, a move to New York City, and starting an internship/work-on-my-thesis at OpenPlans, a neat non-profit in downtown Manhattan. I'm lately plowing through boring details of my software, such as making roads that are incorrectly tagged in Open Street Map render correctly. Though the data is usually accurate enough for my purposes, there are occasional problems that trip up my software:


Everything is inside out here because the boulevard lines in the bottom left (Mass. Ave in Somerville) didn't render correctly. The problem is that whoever or whatever entered data for the boulevard correctly identified that this portion is two one-way streets (separated by a divider) but they accidentally specified the full boulevard width for both ways. This causes the two to overlap and mess up the continuity of the road shapes. I can handle overlapping errors to some extent by detecting some of the offending lines and ignoring them. You can see that my software managed to detect and ignore the extra lines on the left side of the boulevard (again look bottom left) but it left a couple dangling lines further to the right. Those extra lines messed up the polygon of roads. Unfortunately the Open Street Map data doesn't even acknowledge a relationship between the two directions of the boulevard, except that they have the same name. To detect that the boulevard had two lanes and that they were overlapping I'd have to do some fancy tests. The better solution is probably to isolate bad roads like this and render them separately from the other roads. This will be challenging as well.

Open Street Map is designed to make it easy to correct errors in the database, but I don't want my users to have to worry about those details. They should be able to download the data and get a decent rendering of the roads, paths, water ways, and rail. It doesn't have to be perfect, but the above rendering is a non-starter.


No comments: