OpenStreetMap logo OpenStreetMap

AndrewBuck's Diary

Recent diary entries

The OSM dataset is a rich database of information about the world. Not only can the data be used to render beautiful and useful maps, it can also be used to do some nifty calculations in conjunction with other open datasets that exist. One such potential use is in cleaning up and improving elevation datasets such as the public domain SRTM or ASTER datasets. Both of these datasets offer elevation coverage over much of the world but they are limited in resolution (SRTM is 90 m per pixel, ASTER is 30 m per pixel).

Although these elevation datasets can be useful for very basic things like drawing 25 m contour lines on topographic maps, if you try to use these elevation models for more sophisticated things like drainage calculations, you will get very weird results due to a number of issues. First, almost no rivers are 30 m wide or more, so the river channel can’t be modeled at all. Second, noise in the elevation datasets often results in river valleys with “bumps” in the river that make it back up and flood large areas that in the real world would really flood because there is a stream draining the water out of the valley. Lastly, in many areas streams, drainage ditches, and other such things often run in close proximity to buildings and other such features. In these areas trying to fix the elevation to correctly predict drainage ends up changing the elevation of buildings as the pixels are so large the whole neighboorhood must be raised or lowered to make the drainage calculations work. The example shown below shows a couple of these issues, and other areas suffer from them in much more signifigant ways.

The original ASTER data at 30 m per pixel.

See full entry

Location: Laguna Verde, Valparaíso, Provincia de Valparaíso, Valparaiso Region, Chile

In order to better understand the villages in west africa fighting the ebola outbreak currently occurring there, it would be good to have better population data for the towns. One way to do this is to measure the number of buildings per square mile in a typical vilage and then just map a “perimeter” residential landuse area around a village and then work out how many buildings there should be based on the size of the area.

I have been experimenting with this a bit using the data mapped in OSM. As of the time I made this dataset we had 43 small villages in this area that had all of their buildings mapped, as well as a footprint to measure the area. I calculated an average building density of 0.00418 buildings per square meter. Then using this figure I pretended I didn’t know the number of buildings in the town and then re-computed how many there should likely be based on the area. The results are in the graph below, and look quite good.

Actual number vs predicted number of buildings

See full entry

Location: Kensérédou, Kissidougou, Faranah Region, Guinea

Help us map Mali for humanitarian relief

Posted by AndrewBuck on 16 February 2013 in English.

The HOT team is currently working on mapping the country of Mali in response to the conflict that has recently broken out there. One of the big problems we have is that the country is very large, but very sparsely populated. Because of this we need help finding out where to map, i.e. where are all the people.

One of the HOT team members, PovAddict, has put together a nifty little tool for helping us with this problem. At the link below you will be shown a random place in the area we are interested in. If you see a building you click on it, otherwise you click the button to go on to the next one.

Help us out by doing some tiles yourself, and please pass this link around via twitter, facebook, etc. It is a great way for your non-mapper friends to help out the project without having to learn how to map in detail.

http://stuff.povaddict.com.ar/mali-crowdsource/

Location: Mopti Cercle, Mopti, Mali

OSM Server Virtual Machine Available Now.

Posted by AndrewBuck on 13 September 2012 in English.

Over the last few days I have been putting together a virtual machine image of an Ubuntu 12.04 install set up to act as an OSM tileserver and Nominatim server. The Virtualbox virtual machine image boots up and after logging in and running the ‘startx’ command to start the graphical environment, has a “configuration wizard” script on the desktop.

Running this wizard will prompt you to download an OSM PBF extract to the desktop. This PBF file will then be loaded into either a tile rendering database, or a Nominatim database, or both. The configuration is entirely point and click and took about 30 minutes to have a fully functional tileserver and Nominatim server with up to date coastlines downloaded automatically for the Washinton, DC, extract (about a 10 mb PBF extract, processed on a typical dual core PC). I wrote a wiki page about how I set up the virtual machine starting from the bare Ubuntu 12.04 64 bit desktop build to the fully functional server.

The 2.2 gb virtual machine image can be downloaded via BitTorrent using the following torrent file or magnet link. You will find a Readme file in the torrent telling you how to import and boot the image in Virtualbox and further instructions in the VM image itself.

http://data.osm-hr.org/OSM_Server_v0.1.torrent

magnet:?xt=urn:btih:IYDWGYFZYN5CLYRYZOSPH7A7IOKLKPNY&tr=udp://tracker.openbittorrent.com:80

I hope people find this VM fun and useful to play around with. Hopefully now when people want a quick testserver for an app they are developing, or people who want to scrape tiles, or do bulk geocoding can easily download and run this VM on their own hardware, and avoid placing undue load on the OSM community’s donated servers.

Please share any comments or feedback about the VM either in the comments here, or on the talk page on the wiki.

-AndrewBuck

Some new imagery for the Panama Canal

Posted by AndrewBuck on 2 September 2012 in English. Last updated on 3 September 2012.

I was looking through the ISS Imagery and found quite a bit of imagery covering Panama City and the Panama Canal area. This area is almost always cloudy, so the only way to get complete imagery coverage is to combine inputs from many different images taken at different times. All of these images will have clouds over some portion of them, but since the clouds aren’t always in the same place so 2 or 3 sets of imagery covers the area pretty well.

I have put together the first 4 images of one pass by the ISS over the area, there are about 10 more images from that pass that still need to be rectified, as well as 20 or so from other passes to make the cloud free coverage near 100%. Currently between the Bing imagery and the imagery already rectified about 80% of the city is covered. For details on how to load the imagery see the Panama Wiki Page:

osm.wiki/Panama

You can see the imagery layer on an online slippy map on the mapwarper site:

http://maps.nypl.org/relief/layers/22

-AndrewBuck

Location: La Cresta, Bella Vista, Distrito de Panamá, Panamá Province, 0823, Panama

Mapping Trees in Gulu, Uganda

Posted by AndrewBuck on 21 August 2012 in English. Last updated on 22 August 2012.

Last week the Red Cross put up some imagery of two cities in northern Uganda. The towns are being armchair mapped by tracing buildings and trees over the city and Red Cross volunteers will be on the ground in a few weeks to collect information to fill in the map details.

One of the goals of the mapping project is to measure the fire risk within the city. Gulu has thousands of small circular huts with grass roofs, many of which are densely clustered together. Furthermore, there are quite a few trees throughout the city and in a fire these could burn as well.

The mapping of the city is progressing rapidly, roads are mostly done and the buildings are nearing completion as well. Tree coverage is almost 100% in the areas that are mapped, but only about 30% of the city’s area has been covered for trees yet.

I have been working out an efficient workflow for mapping the rest of these trees (and any other ones people want to map) efficiently and accurately. I do the work in two passes. First, I just go through an area and put down untagged nodes on all the trees in the area (going methodically to make sure all are done in one pass). Holding down shift in add mode lets you just do a single click for each tree, very easy to do lots of them quickly like this. Then I click the upload button in josm and cancel the upload so the validator lets me select all the untagged tree nodes and add tags to them (this can be done with all of them in a single operation by double clicking on the group name to select them all). After all the newly created trees have been properly tagged I upload them to the server so they are visible to other mappers so they won’t duplicate them in their own mapping efforts.

See full entry

Location: Green Valley, Gulu, Northern Region, Uganda

I came across this article on the BBC news this morning and thought the OSM community would be interested in it. It discusses the way the Kabul post office delivers letters to people, given that most of the streets are unnamed and the houses are not numbered.

The "addresses" instead tend to be the recipient's name, along with some rough directions for how to find them, like "near the such and such mosque", or "by the local high school". Given that this is how deliveries are done in this area (and probably many other areas like it), I thought it would be good to show this to everyone so they can have some insight into what kinds of things might be useful to map for people in these areas. It seems like POI's and landuse may actually be more useful than street names for finding your way around, since many streets are unnamed or only informally named.

http://www.bbc.co.uk/news/magazine-14806350

-Buck

I was looking at the wiki and came across the page osm.wiki/Potential_Datasources which lists many existing datasets as well as links to people who have imagery we may be able to make use of. One of these sources is the images taken by astronauts aboard the International Space Station. The images are taken with an off the shelf camera and a very long lens (800 mm focal length). The resulting ground images can be quite detailed and are often of intersting places, many of which are not covered by Bing or Yahoo.

I thought I would look up Libya (as it is a current HOT project) expecting to find one or two images but was pleasantly surprised to find dozens of them. I have uploaded to MapWarper two of the images covering Misrata during the day (an area where our map is very bad due to no hi-res imagery) and plan to also upload one of the Misrata at night images which shows a larger area, as well as one for Surt.

Surt is a particularly interesting case as we have a very poor map of it (again due to lack of imagery), but it is also the hometown of Muammar Gaddafi making it one of the strongholds for the current government. I will try to get the Surt and Mirata at night photos up on mapwarper later today. If anyone wants to upload them before that to start working on them earlier, please respond to this diary entry so I know not to upload a second copy.

Below are the links to the two images already on mapwarper. The description is all run together (mapwarper doesn't display the newlines in the description) but they contain the original NASA url and the source tag you should use for tracing (which is really long unfortunately).

http://warper.geothings.net/maps/4614
http://warper.geothings.net/maps/4615

If you follow the links above to the mapwarper images there is an 'Export' tab which has the links you need to use the imagery in JOSM or Potlach.

See full entry

Location: Almagaasbah, Misrata, Bani Walid, Libya

A thank you regarding Libya

Posted by AndrewBuck on 22 July 2011 in English.

A thank you regarding Libya

I would just like to take a moment to say thank you to those who responded to my diary entry asking for help working in Libya. When I made the post, the area between Zlitan and Al Khoms was almost totally unmapped, now it is hard to find unmapped roads in the imagery.

Thank you to all those who helped out with the mapping effort, it would have taken me many weeks to do what was done by others in just the first few days after I made my post. I will continue to fill in details in this area (and hope others will continue as well), but I think at this point we can say we have a pretty decent map, and one which for this area seems to be one of the best around. OpenStreetMap, and the HOT team, continue to amaze and inspire me -- here's hoping both projects continue even after we have mapped the whole world to this level of detail.

-Buck

P.S. Here is a link to the area on OSM as well as a comparison with Google so you can see how well it is now mapped.

osm.org/?lat=32.547&lon=14.391&zoom=10&layers=M

http://tools.geofabrik.de/mc/?mt0=mapnik&mt1=googlemap&lon=14.37736&lat=32.53313&zoom=10

I finally got around to setting up my own tileserver with the idea of playing around with the mapnik stylesheet to try to resolve some of the issues it has. I have noticed that there are a lot of issue (~300) currently outstanding against the mapnik sheet and only about 3 names in the "assigned to" fields of these tickets, so I have decided to try working through some of them on my local tile server here so I can submit patches to the trac tickets allowing them to be resolved.

In doing this however I see that there are many "duplicate" rules in the stylesheet. There are several ways in which the duplication occurs and some of it makes sense (progressively more specific rules about a certain road type for example), but some of these are redundant, or even outright copies in the filter string with different styles specified for the exact same set of roads, meaning that it can be very difficult to find out which rule even applies to a given way.

I will try to put some patches together to remove some of the more egregious duplicate entries and submit them shortly via trac tickets. If anyone has any insight into why there seems to be so much duplication I would appreciate your insight as I am new to mapnik and have much to learn. Feel free to either respond to this diary entry, or get in touch with me on Skype (username andrewbuck40) if you want to text/voice chat about this, or any other mapnik style related issues.

-Buck

Libya has been designated as a HOT project area for a while now due to the on-going hostilities there. There is hi-resolution imagery on Bing for the Tripoli area which is already pretty well mapped, however there is also imagery for the cities of Al Khums and Zlitan which has a lot of un-mapped area in it.

The conflict has been at a stalemate for a while, however just in the last few days the rebels have begun to advance again. The BBC reports that the rebels have started pushing westward from Misrata toward Zlitan, and they are also advancing northward from Gharian toward this same area.

Whether the rebels are able to use OSM in their activities or not, we know that various aid organizations do monitor it for coordinating their efforts. It would be nice if we had the area completely mapped as best we can from the existing imagery by the time these aid organizations move into the area.

Here are the stories from the BBC referenced above, as well as the bounding box of the hi-res imagery for the area so you can see where to work. Tomorrow I will try to put together another diary post detailing specific things that I think would be useful to map, as well as techniques for spotting them in the imagery.

Libya: Rebels continue to push west from Misrata
http://www.bbc.co.uk/news/world-africa-14094671

Libyan rebels advance towards key town south of Tripoli
http://www.bbc.co.uk/news/world-africa-14066968

The Bing Hi-res Bounding Box
osm.org/browse/way/101311397