JOSM Address Interpolation plugin

I’ve create a JOSM plugin to easily create Address Interpolation ways. I haven’t checked it in yet, so it doesn’t show up in the plugin list. I’m looking for feedback -

Did I get the relation right? I think so, but after using it a bit, I think I should discard the idea of associating by street name, always associate by relation, and just create the relation if it does not yet exist.

Any other suggestions?

Wiki page:

I have not tried the plugin, but have a quick question:

What gets added to the associatedStreet relation? The interpolation way, or the addr:housenumber nodes therein?

But: bloody brilliant! I just mentioned needing something like this in JOSM to a few ppl on #osm-nl, and look what you cooked up! Great! :slight_smile:

PS: We would also need a way to add further addr:housenumber nodes (that are inserted into the interpolation way) to the appropriate relation as well.

Currently, I only add the interpolation way to the associatedStreet relation - I believe this matches the examples in the Wiki. But since I’m automating, it wouldn’t hurt to add the 2 addr:housenumber nodes since they will be there in a final configuration.

I’m not sure that nodes in the middle of the address interpolation way are a good candidate to automatically add to the relation unless someone has already assigned them an addr:housenumber before invoking the Address Interpolation dialog. How would the work flow look that routinely creates the addr:housenumber nodes in the middle of the way?

I don’t know which wiki pages you are looking at, but I’m working from, which definately does not add the interpolation way to the relation. Since the interpolation way was designed to be a temporary construct, until all houses on the stretch of road it covers have been entered individually, it has no place in the associatedStreet relation. Only the nodes have to be added as members, in addition to the (section of) street to associate those nodes with.

I’ve stuck with the addr:street tagging on the nodes, since it’s much faster to enter. But if I did associatedStreet relations, I would probably do this:

  • Create interpolation way with 2 nodes. Tag it, and tag the two nodes with addr:housenumber.
  • If necessary, create any interim nodes into the interpolation way while creating it, or after it’s been created, and any individual nodes outside of the interpolation way, but still for that stretch of road. The latter is commonly needed when you start off with numbers like 1a, since those cannot be on the end nodes of the interpolation way.
  • Create associatedStreet relation, add the nodes and the associated street as members.

Using the plugin, you’d have to account for 2 scenarios.

  1. You create an interpolation way with 2 tagged nodes, and create the relation with that. That’s what you’re currently doing.
  2. After that’s done, extra nodes are created in the interpolation way and tagged accordingly, or individual nodes are created that have to be in the relation as well. Select those nodes, and the street to associate them with, and invoke the plugin again. The plugin then recognizes that the relation already exists, and only adds those selected nodes to the relation.

As I read it -

does refer to the address interpolation way. Otherwise there would be extra steps required to locate the address interpolation way in software:
collect all ways spatially close to the street.
Inspect for type address interpolation and end nodes part of the relation.

Also if the address interpolation way is ever deleted in the future, it will also be deleted from the relation.

I think I understand about how the selected nodes would work. So I think the following changes would apply:

  1. Always create using a relation (no choice for the user).
  2. Scan all selected nodes and all nodes on the address interpolation way for addr:housenumber, and automatically add to the relation if not already present. This can be done at the same time the address interpolation is created, or later.

For the case where just nodes are added later to the relation, it is functionally the same as adding them to the relation with an automatic role=house.

What’s the reason for forcing relations?

associatedStreet relations are clearly less popular than association by name, and there seems to be some support for focussing on addr:street in the future. (For example, OSM Inspector only evaluates association by name - intentionally, according to recent mailing list discussions.) Association by relation also seems to decrease (certainly not increase) usability for human mappers, which should be the primary concern.

The only reason for forcing relations would be that the plugin makes it simple now. New users will create roads with an abbreviation (I was guilty of this at first). That would break the street<>Address association after the name is corrected.

But it is good to know that there some people want to focus on addr:street as the association. And you have a good point about relations being harder for human mappers. It took a while to wrap my head around the associated street relation. And even with the wiki reference page, there are multiple interpretations of the relation based on the comments by Ldp.

So, I would propose to keep the current plugin behavior.

  • Default to association by street name.
  • Honor an associatedStreet relation if it exists.

Thanks for your comments.

I’ve checked the plugin into SVN and it should show up for download now.

Thanks for providing this plugin. Comes in very handy, as I’ve just started to input house numbers in my area.

Since you asked for suggestions:

It would be useful if the plugin would work with a single node/building and a street, too, instead of only a way and a street. That way one could add a building (closed way) or a simple house node to the associatedStreet relation.
In the UI, it’d be enough to grey out the widgets for Ending # and Numbering Scheme. Then one could input the house number, and the plugin would tag the selected node/building with addr:housenumber and create the associatedStreet relation, or add the node/building to an already existing relation of the selected street.

That doesn’t save much time for mappers who use addr:street for the association. But for those of us who prefer the associatedStreet relation it’d be a great help. Might even serve to further the cause of using the relation method. :wink: To me, the concept of storing the same - or, often enough, slightly different versions of a - street name in dozens of nodes looks very bad, indeed.

You can associate address number nodes in a limited fashion today:

1.) Create a node
2.) Assign addr:housenumber to the node.
3.) Invoke the Address Interpolation plugin while selecting just the node and street. You can create the relation from there also if desired.

So - will it be worth the improvement to add a mode where selecting single blank node plus street will ask for the house number?

That will also work while selecting the street and multiple nodes that already have addr:housenumber assigned.

Adding a closed way (building) to the street ‘associated’ role of the relation begins to stray outside the focus of the plugin, and the ‘collected / associated’ street relations are still at the proposed stage, if I read correctly.

Oh, excellent. I didn’t realize the plugin can set up the relation that way, only tried it with an untagged node.

That makes an extension like the one I suggested definitely unnecessary.

Update to this plugin:


  • Add address interpolation accuracy tag (From Anthony’s idea)
  • Add numeric interpolation type
  • Add option to convert address interpolation way to individual house numbers according to the defined rule. This means that the plugin is useful even if you are not using address interpolation ways, but creating individual housenumber nodes.

You’ll need to update to the latest JOSM-tested to use this.