[Talk-GB] OSM UK's first tile layer

Rob Nickerson rob.j.nickerson at gmail.com
Mon Oct 26 21:49:14 UTC 2020


Hi all,

A few more tiles added to help test the alignment. I've added the following
locations:

    # Colchester
    bbox = (0.8895, 51.8831, 0.9190, 51.8974)
    render_tiles(bbox, mapfile, tile_dir, 17, 17 , "Colchester")

    # Flamborough
    bbox = (-0.132106, 54.102325, -0.111807, 54.121253)
    render_tiles(bbox, mapfile, tile_dir, 17, 17 , "Flamborough")

    # Stornoway
    bbox = (-6.414124, 58.198201, -6.250257, 58.238161)
    render_tiles(bbox, mapfile, tile_dir, 17, 17 , "Stornoway")

    # Scilly
    bbox = (-6.331023, 49.909491, -6.287335, 49.928125)
    render_tiles(bbox, mapfile, tile_dir, 17, 17 , "Scilly")

Just zoom level 17 for these areas for now.

These tiles were created without first converting from British National
Grid to WGS 84 (lat/lon). Instead I pass Mapnik data in British National
Grid projection and Mapnik transforms it to the web projection. The good
news is that it hasn't altered the final result and that this still matches
the result from the Land Registry's WMS service. So we can say that we are
transforming the same way that their WMS service is.

The bad news however is that if I used the link Adrian provided [1] to
transform to ETRS89 and compare to the coordinates that I can read out in
JOSM, it does indeed look like we have an error. For example in Scilly,
checking just one point, I get an adjustment of 4.8 meters which is almost
identical to the 4.7m error that Adrian highlighted.

So in summary, more work is required. I will keep chipping away at this.
Fortunately the Scottish data is published in both ETRS89 and British
National Grid so I can check those in detail (assuming the Scottish data
has been transformed correctly).

It does beg the question, what do we want to map to as our reference point?
My knowledge on these matters is very limited and based on just one article
[2]. My reading of this is that ETRS is a reference system for Europe but
that if you want to adjust to the International version then you get the
problem of the continental plate shifting 2.5cm per year. ETRS89 dates from
1989 so 31 years later we have a (31 x 2.5 = ) 77.5cm shift. Noticeable but
nowhere near as bad as the 4.7m issue with the crude transformation from
the british national grid.

[1] https://www.ordnancesurvey.co.uk/gps/transformation/
[2]
https://novatel.com/support/known-solutions/wgs84-to-etrs89-datum-transformations

Best regards,
*Rob*


On Fri, 23 Oct 2020 at 21:53, Rob Nickerson <rob.j.nickerson at gmail.com>
wrote:

> Thanks for this.
>
> I'm still confused as to what exactly I need but at least I can run some
> tests using these places. If it helps anyone, below is the xml we are using
> in Mapnik. The Map srs is from the OpenStreetMap default render and relates
> to the web projection. The Layer SRS is the standard for WGS84.
>
> The intent going forward is to not transform from the british national
> grid to WGS84 before feeding in to Mapnik. Instead I will give Mapnik the
> raw data and the relevant Layer srs. I believe this is "+proj=tmerc
> +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=400000 +y_0=-100000 +ellps=airy
> +datum=OSGB36 +units=m +no_defs" based on the link at
> https://spatialreference.org/ref/epsg/osgb-1936-british-national-grid/ I
> will test this but if you or others have feedback at this stage, please let
> me know.
>
> <Map srs="+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0
> +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs +over">
>
>   <Style name="My Style">
>     <Rule>
>       <LineSymbolizer stroke="rgb(100%,0%,0%)" stroke-width="4" />
>     </Rule>
>   </Style>
>
>   <Layer name="world" srs="+proj=longlat +ellps=WGS84 +datum=WGS84
> +no_defs">
>     <StyleName>My Style</StyleName>
>     <Datasource>
>       <Parameter name="type">shape</Parameter>
>       <Parameter name="file">york.shp</Parameter>
>     </Datasource>
>   </Layer>
>
> </Map>
>
> *Rob*
>
>
> On Mon, 19 Oct 2020 at 20:02, Adrian <ar2988-os2 at yahoo.co.uk> wrote:
>
>> The Ordnance Survey provides a transformation between OSGB36 and ETRS. It
>> is described on this page
>> https://www.ordnancesurvey.co.uk/gps/transformation/ and on the pages
>> linked from there. The transformation is definitive. In other words, OSGB36
>> is redefined as being what you get when you apply the transformation to
>> sets of ETRS co-ordinates. This must mean that if you compare an OS 1:1250
>> National Grid plan, with an older version of the plan from the era of
>> OSTN02, features may have shifted slightly.
>>
>> The transformation involves a mathematical transformation, and an
>> adjustment based on a look-up table, to make the result match the errors in
>> the old triangulation system. The OS provides applications to do the
>> transformation, both ways, for a range of platforms. It also provides
>> source code, the look-up table, and details of the mathematical
>> transformation.
>>
>> JOSM handles projections using proj. If you want to know what JOSM does
>> with EPSG:27700, you need to know how it is defined in proj. The source
>> code of JOSM includes the OSTN02 look-up table (15MB), but it can't be in
>> the jar (also 15MB), so I don't know how that works.
>>
>> Rob asked about position errors from the Helmert transformation without a
>> look-up table. Here are some examples.
>> Larger errors
>> Place             error, m
>> St Kilda           4.9
>> Scilly             4.7
>> Lizard Point       4.1
>> Butt of Lewis      3.2
>> King's Lynn        2.7
>> Mallaig            2.6
>> Flamborough Head   2.4
>> Colchester         2.4
>> Plymouth           2.4
>> Nottingham         2.3
>> Anglesey           2.1
>> Northampton        2.0
>> North Foreland     1.9
>> Isle of Man S      1.9
>> Carmarthen         1.9
>> Smaller errors
>> St Catherine's Pt  1.4
>> Carlisle           0.8
>> Edinburgh          0.6
>> Aberdeen           1.8
>> Thurso             1.6
>> Orkney             1.0
>> Foula (Shetland)   1.2
>> The errors are particularly small near Bristol, Edinburgh and Fair Isle.
>> They exceed 2m in South Devon, Cornwall, East Anglia, Nottinghamshire,
>> Lincolnshire, the East Riding of Yorkshire, Pembrokeshire, Anglesey and
>> Western Scotland.
>>
>> +1 for referencing GB to ETRS.
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/talk-gb/attachments/20201026/29cb3e07/attachment.htm>


More information about the Talk-GB mailing list