OS Grid references

How do I download UK observations with OS grid references? I can only get lat long which is no use to me. I thought there would be an option for OS for inaturalist uk.

you can download the CSV and use some sort of conversion program or tool to make the conversion.

if you’re trying to get records into a format to import to iRecord, you might be able to adapt some Python code created by @sbushes here: https://forum.inaturalist.org/t/tool-for-exporting-inaturalist-data-to-irecord-or-elsewhere/19160.

this example uses the OSGridConverter module to make the conversion, i think, and you can also use that if you’re writing your own thing in Python to make the conversion.

if you need more help or examples, please describe why you need the OS grid references, and maybe you’ll get more help.

1 Like

basically I need it to be able to send my inat records to various recording schemes and record centres that don’t routinely download inat data themselves.

did you look at sbushes’s script? i think that does what you’re trying to do.

I looked at it but it’s from 3 years ago so was hoping for something better/easier.

There isn’t a one-click export from iNaturalist that includes OS grid references.

this will do a batch conversion but it’s not ideal https://gridreferencefinder.com/batchConvert/batchConvert.php

There isn’t a one-click export of observations* from iNaturalist.org* that includes OS grid references.

1 Like

hmmm… you’re not saying that it doesn’t work.

what’s wrong with that solution? seems like you have so many available solutions.

you should talk to your iNaturalistUK admins to see if they have any tools that might be even easier, if that’s what you’re looking for.

…

i was working on some Python code for working with iNaturalist data, and i was going to work on a script next that loads data from CSV files and does some processing on them, but i don’t know when i’ll get around to publishing a version of that. that future thing could be adapted fairly easily to get OS references.

but in the meantime, i think you could adapt my already published notebook for getting observations observations from the API to get some OS Referenced observations. i don’t know that this would be better than sbushes script, though running code on my JupyterLite deployment should be a little faster than going through sbushes’s code in Binder.

the key changes needed to adapt my stuff would be:

  1. add a line to import the needed conversion function:

    from OSGridConverter import latlong2grid
    
  2. after the line that begins with obs = (in the main execution section), add the following code (based on https://pypi.org/project/OSGridConverter/):

    for o in obs:
    if obs.get('latitude') is not None and obs.get('longitude') is not None:
        g = latlong2grid(obs['latitude'],obs['longitude'])
        obs['os_reference'] = str(g)
        obs['os_reference_east_north'] = f'({g.E},{g.N})'
    
  3. change the line that sets req_params_string = to whatever you need your observation filter parameters to be.

  4. on the obs = line, set get_all_pages=True so that you’ll get the maximum number of records available from the API.

3 Likes

that’s all just way too techy for me. I was assuming since inat data routinely migrates to irecord presumably with OS co-ordinates there would be a simple solution people are using. I have managed to do it using the grid ref converter but it has taken a couple of hours for 4000 records.

my script should still work - it might look intimidating, but it´s really not
if you want help to do it, direct message me and I can help you get what you need

3 Likes

One other solution (which probably isn’t feasible, but is really ideal), is to convince these agencies/centers to use/accept decimal coordinates. OS grids are relics and should be consigned to the past for use in biodiversity studies/monitoring in my opinion.

I would guess that irecord converts the the decimal coordinates (which is the system that iNat and most entities use) to OS grid refs themselves. Why they make it harder for folks to give them data by requiring those people to find/convert the OS coords themselves, when presumably irecord (or any entity) could do it on their own in a standardized way, is unclear to me.

3 Likes

The national UK recording schemes are all run by different people, almost entirely/entirely volunteers.
In Diptera at least it’s mainly just a single expert for a single family. Wonderful to have that expertise to communicate with. But unfortunately they all have there own way of doing things. Some prefer csv files, some iRecord, a few iNaturalist. One of the oldest and most knowledgeable ones I communicate with seems to prefer just a direct email with photos attached.

iRecord was the effort many years ago to bring these schemes altogether and standardise the recording schemes better. Unfortunately not everyone found the system to their liking… there are just too many different people involved, each with their own preferences.

iRecord should definitely have an upload option for lat/long … but …iRecord should have many things!
The whole system is incredibly clunky and needs loads of work imo.
Presumably just a lack of funding… or I don’t know… they just need better devs/designers.
The horrors of the user interface are why I gave up using it.

But to some extent this doesn’t matter now there is a data bridge reinstalled.
The iNaturalist records are automatically sent over and converted on import by iRecord.
From iRecord they are accessible by any records centre or recording scheme in the format they need.

Curious which recording schemes you are doing this for @Major_Bombylius ?
I thought most of the larger ones just take from iRecord, and the records centres too.

2 Likes

it’s OK thanks (for now) as I managed to convert them all on my spreadsheet (with some difficulty!)

1 Like

Some smaller LERCS (and bigger ones) don’t touch inaturalist or irecord. Also only research grade reach irecord. Also there is a problem at the moment with even research grade not reaching irecord. It’s an irecord bug they haven’t fixed yet.

1 Like

are you saying it took you a couple of hours just to do the OS Grid conversion?

the tool you referenced should be able to convert multiple records at once, and if you use a spreadsheet program like Excel, you should be able to paste in tons of records and copy out the results, too. if it’s just the OS Grid conversion that took you that long, i think you could could probably improve your workflow to speed things up greatly. (i’m thinking the conversion shouldn’t take more than a few seconds.)

Ok, well… feel free to drop me a line if you need help with it next year :)

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.