# Can't convert from Irish to British grid using CoordRefSystems

**URL:** <https://discourse.julialang.org/t/cant-convert-from-irish-to-british-grid-using-coordrefsystems/121857>\
**Category:** Performance\
**Tags:** geo\
**Created:** [October 28, 2024, 9:31am UTC](https://discourse.julialang.org/t/cant-convert-from-irish-to-british-grid-using-coordrefsystems/121857 "2024-10-28T09:31:04Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![TimG](https://avatars.discourse-cdn.com/v4/letter/t/82dd89/32.png) [@TimG](https://discourse.julialang.org/u/TimG)\
**Post date:** [October 28, 2024, 9:31am UTC](https://discourse.julialang.org/t/cant-convert-from-irish-to-british-grid-using-coordrefsystems/121857/1 "2024-10-28T09:31:04Z")

</div>

I’m trying to convert coordinates from Irish to British national grid. I can do this in Proj, but am encountering some compatibility issues. I thought the easiest solution might be to remove any direct dependence on Proj and use CoordRefSystems.jl

```julia
    using CoordRefSystems
    x= 337492.0
    y= 374065.0
    ing = CoordRefSystems.get(EPSG{29903}) # Irish National Grid
    bng = CoordRefSystems.get(EPSG{27700}) # British National Grid
    println(ing(x, y))
    bng_xy = CoordRefSystems.convert(bng, ing(x, y))

```

I took this from the examples in the docs, [here](https://github.com/JuliaEarth/CoordRefSystems.jl?tab=readme-ov-file#epsgersi-codes).

However, this doesn’t work. What am I doing wrong?

I get the following output:

```julia
TransverseMercator{Ire65}(x: 337492.0 m, y: 374065.0 m)

ERROR: MethodError: no method matching transform(::Type{Ire65}, ::Type{OSGB36})
The function `transform` exists, but no method is defined for this combination of argument types.

Closest candidates are:
  transform(::Type{<:WGS84}, ::Type{<:OSGB36})
   @ CoordRefSystems C:\Users\TGebbels\.julia\packages\CoordRefSystems\V4i7O\src\transforms.jl:39
  transform(::Type{<:Ire65}, ::Type{<:WGS84})
   @ CoordRefSystems C:\Users\TGebbels\.julia\packages\CoordRefSystems\V4i7O\src\transforms.jl:38
  transform(::Type{<:WGS84}, ::Type{<:GGRS87})
   @ CoordRefSystems C:\Users\TGebbels\.julia\packages\CoordRefSystems\V4i7O\src\transforms.jl:39
  ...

Stacktrace:
 [1] convert(::Type{Cartesian{OSGB36}}, coords::Cartesian3D{Ire65, Unitful.Quantity{Float64, 𝐋, Unitful.FreeUnits{…}}} )
   @ CoordRefSystems C:\Users\TGebbels\.julia\packages\CoordRefSystems\V4i7O\src\crs\basic.jl:361
 [2] convert(::Type{GeodeticLatLon{…}}, coords::GeodeticLatLon{Ire65, Unitful.Quantity{…}})
   @ CoordRefSystems C:\Users\TGebbels\.julia\packages\CoordRefSystems\V4i7O\src\crs\geographic\geodetic.jl:239
 [3] convert(::Type{…}, coords::TransverseMercator{…})
   @ CoordRefSystems C:\Users\TGebbels\.julia\packages\CoordRefSystems\V4i7O\src\crs\projected.jl:194
 [4] top-level scope
   @ REPL[57]:1 

```

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [October 28, 2024, 11:06am UTC](https://discourse.julialang.org/t/cant-convert-from-irish-to-british-grid-using-coordrefsystems/121857/2 "2024-10-28T11:06:28Z")

</div>

Hi @TimG , CoordRefSystems.jl doesn’t support custom grids yet, but we plan to add this feature very soon, to fully replace the PROJ C library.

To give some extra context, some countries provide “adjustments” to coordinate conversions, which are saved as grid data. We need to load these artifacts and apply the adjuments in the case of the National British grid, for example.
