Replies: 1 comment
-
You need to give us some more context here. For starters, there is a world of difference if you want to convert from geojson to osm format or vise versa. Then OSM relations are tricky, because there isn't necessarily an equivalent datatype in geojson. You'd need to tell us what kind of relation (or what kind of data in geojson) you are working with. Next it looks like you are working with a OSM change file from JOSM. Those are different from OSM data files. I haven't gotten around writing the chapter on diff files yet, but essentially you need to name your output file Finally, did you know that JOSM can load and save geojson directly? This might be sufficient for your use case or not. Again, it would be good to know what the problem is that you are trying to solve not just the parts of the solution where you are using pyosmium. |
Beta Was this translation helpful? Give feedback.
-
I actually try to convert between geojson and osm. Somehow it is incredibly hard to pull off. I have wasted 3 days. At least I could build some understanding of the 2 formats that I never used before.
Either I am dead stupid (likely) or the library is a bit awkward to use. I can easily imagine that it is fun to change existing osm files using replace or just filter for relevant data.
I would like to see some examples how you generate new relations.
When I create a relation like this and add it to the writer then the
visible
attribute is lost. In the original osm file the relation looks like:What do I need to do to add an action attribute?
Beta Was this translation helpful? Give feedback.
All reactions