Osmdiff

From OpenStreetMap Wiki
Jump to: navigation, search
Example output showing differences

osmdiff is a perl script by Gary68 which takes two .osm files (with hopefully the same bounding box parameters) and compares them to find differences in ways and nodes.

Output is

Contents

Helpful links

Data

Reports

Some reports can be obtained here: osmdiff reports

Example

A very big file (3.2MB, 8.192 x 12.110 pixels) of Hessen/Germany (two weeks of activity) can be seen (or better downloaded) here: osmdiff_hessen_example.png

Features

Files are searched for

The collected information is written into the html file and drawn in the picture.

The picture shows

The user names shown in the picture are the centers of activity for this area and time (only taking into account changed and added nodes).

Download and Hints

osmdiff.pl in SVN

Installation

E.g. on Debian

1) Install perl

2) Install Module GD

apt-get install libgd-gd2-perl

3) Create directory OSM (e.g. in /usr/lib/perl5/ )

Copy Osmgraph.pm from the Osmgraph.pm page to /usr/lib/perl5/OSM/

Usage

Usage: osmdiff.pl file1.osm file2.osm output.htm pic.png [size [thickness [C]]]" .

Resources

Program needs a lot of RAM. So start with small files. Of course this depens on your machine. If you have 1GB RAM it is a good idea not to use files with more than 200/300MB of size. And use a small picture size. Also consider the size of the HTML output file since EVERY change is documented!

Data

There are (at least) two ways to obtain data for this tool:

It is (more or less) important to clip the output of OSM API/XAPI to a rectangle to get good results in the picture drawn. As you know the API returns complete ways although some nodes may be outside the initially given bounding box. There are (at least) two ways to do this:

Next version

Personal tools
Namespaces
Variants
Actions
site
Toolbox