Hi , I want to find rail distance between multiple pairs of stations. I understand OSM database is subset of OpenRailway Map data. Can I get the required information from *.osm/pbf file or do I have to access OpenRailway Map server using APIs ?
Hi.
It’s more the reverse, OpenRailwayMap displays a subset of OpenStreetMap data. So yes, you could extract railways from an osm/pdf dump. But you’ll get a lot more data than you need, and then you need to calculate the routes… Quite some work.
If you need only a few distances, it will be simpler to use an online router which support train lines. For example, osmand on the web provides this option. I also just found signal.eu…
Hope this helps.
Best regards.
You are looking for a routing engine which is able to route on tracks. Consider using OpenRailRouting by Geofabrik. A public demo instance for experimental use can be found at routing.openrailrouting.org.
Thanks and Yes, It helps indeep but I want a scalable/repeatable and programatically way to extract distance as this is not one time activity and for it,OpenRail Routing will work. Ready to do some hard work once dbf file is loaded into PostGIS/PostGresSQL. Any article/blog on how to proceed further will be helpful.
You can start by the routing page on the wiki. It’s mostly for roads, but you’ll find useful information and pointers I think.
If you want to install OpenRailRouting, check the github linked by @Nakaner, there are some instructions… Also it says that it’s a fork of GraphHopper, so you can find information there also.
Regards.