Firstly I need to overlay a grid in JOSM. The grid should be 1,5 km^2 per square and should cover the data layer in JOSM.

Secondly I need to run the built in validator for each square on the grid, presenting me with the number of errors for each grid square.

Thirdly I need to export the information into Excel to process the data. Something like square 1 has 3 errors for 'unnamed ways', square 2 has 6 errors for 'unnamed ways', etc.

How can this be achieved?

asked 16 Sep '15, 21:38

BmanS's gravatar image

BmanS
56447
accept rate: 0%

edited 17 Sep '15, 05:53

aseerel4c26's gravatar image

aseerel4c26 ♦
31.9k16237548


This is definitely not achievable without some programming and some modifications to JOSM.

You will have to split the data into squares first, using e.g. osmconvert, osmosis, or osm-history-splitter, and you will have to write a small program that computes the grid and executes one of these programs to achieve the splitting.

After that, your choices are either to modify JOSM so that it can run the validator from the command line and output results as CSV or similar, or you could drop JOSM altogether and use the open-sourced check utilities KeepRight or Osmose which might be more amenable to such a modification than JOSM which is geared towards interactive editing.

permanent link

answered 16 Sep '15, 22:24

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
68.9k806261076
accept rate: 24%

edited 16 Sep '15, 22:34

I expected some programming.

How do I do all that? Or where can I read up and learn how to do it?

I already modified the JOSM validator to search for specific things I am interested in which I could not do with the other validation tools. So I have the validator tool already set up. However now I need to split the data into grids and have the validator validate one grid at a time. How can I split the data with osmconvert, osmosis or osm-history-splitter and then write that program?

(17 Sep '15, 08:13) BmanS

An easy way to programatically download squares is to use the remote control.

That doesn't help you with the validatetion process, but if you've started modifying the validator code already you could try to register a remotecontrol handler for the validator that returns the errors in a parseable format. That actually sounds like a useful feature, consider upstreaming it if you implement it.

(17 Sep '15, 10:10) Vincent de P... ♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×502
×13
×12

question asked: 16 Sep '15, 21:38

question was seen: 2,141 times

last updated: 17 Sep '15, 10:10

powered by OSQA