Railway Signal Geodata Translation
August 29, 2012 7:02 AM   Subscribe

Does anyone know of a way to convert Network Rail Engineering Line Reference linear positional data into OSM Eastings and Northings En Masse?

I have a large excel spreadsheet of railway signals which are referenced with ELR and a miles and yards position.

I need to convert these into Eastings and Northings (or any other freely exchangable map data). Problem is, the systems I have access to are incredibly archaic. I can look up one ELR location at a time and read off on the map the position. This is going to take me way to long to convert the thousands that I have.

I realise that this is an incredibly niche question, but you've surprised me in the past.
posted by Just this guy, y'know to Travel & Transportation (7 answers total) 1 user marked this as a favorite
 
Problem is, the systems I have access to are incredibly archaic. I can look up one ELR location at a time and read off on the map the position.

You mean, on a physical map?
posted by atrazine at 7:31 AM on August 29, 2012


Response by poster: No, I have a Geodata system which will let me look up an ELR + Miles:Yards and highlight it on a map (onscreen). I can then move a cursor over the marked location and read off the data.
posted by Just this guy, y'know at 7:37 AM on August 29, 2012


Do you have any more information on the Geodata system? Presumably there must be some kind of database or file that it's pulling that information from.
posted by atrazine at 7:58 AM on August 29, 2012


Do you have access to ArcMap? I am pretty sure you could solve that problem in gis, though ideally you could do it within your current system.
posted by Forktine at 8:24 AM on August 29, 2012


Response by poster: The geodata system is accessed through Internet Explorer.
It presents a map square with directional arrows to move to the next map square. One of the buttons lets me input ELR and line reference and if can then either Pan or Zoom to a blue cross marked on the map.

Easting and Northing location of the cursor is shown on the statusbar, so I can put my cursor over the X and read off where it is.
Sadly it seems to AutoIt this process I would need to do visual processing as well to find the blue X. Otherwise I think that might have worked.

I assume it has some sort of database, but it is not one that I am allowed to access sadly, or I would dive into that.
posted by Just this guy, y'know at 8:24 AM on August 29, 2012


If you really cannot get at the underlying database that the application uses -- which would really be the best way to do things, since that database is the key to the whole operation -- then you need to look for an API or pseudo-API. If that fails, then I'd look at UI scripting.

What I'd do is start looking at the source for the web application, especially at any client-side Javascript, if there is any. (If it's a Java applet then you may need to decompile it, which is a pain.) Basically you want to figure out how it's submitting the input data to the server. If it's something simple -- ideally, just putting it into the URL somehow -- then you could probably write a small utility that takes your ELR positions, submits them, parses the output, and gives you your results in some structured format. If I had to complete that task, I'd probably do it in Python and Beautiful Soup or some other messy-HTML parser. But that's just my preferred hammer.

If that doesn't work then I'd script the UI. Some automated test tools can be used to repeatedly query web forms. I'd look at Selenium (though that's just because I'm familiar with it). But you are talking about a significant amount of work here.

If this is a task that someone is paying you to do, make sure that they're aware that your lack of access to the underlying database is turning what could potentially be a very quick task into what is realistically a week or more worth of work.
posted by Kadin2048 at 11:06 AM on August 29, 2012


How accurate do you need this to be? If you know the start and end points of the line segments, then you could use OpenStreetMap data (which has a lot, if not all of the UK rail network mapped) to track along the line the appropriate distance to find the location of the entries in your database.
posted by pharm at 1:55 PM on August 29, 2012 [1 favorite]


« Older All together now: "Eat the Rich!"   |   Lost 100lbs, had a baby & gained it all back.... Newer »
This thread is closed to new comments.