Skip to content

failing to interface to planar ugrid#57

Open
mo-marqh wants to merge 2 commits intoMetOffice:mainfrom
mo-marqh:ugrid_meta
Open

failing to interface to planar ugrid#57
mo-marqh wants to merge 2 commits intoMetOffice:mainfrom
mo-marqh:ugrid_meta

Conversation

@mo-marqh
Copy link
Member

@mo-marqh mo-marqh commented Jul 3, 2025

this code should set up an XIOS conteaxt from an input mesh file

note code is XIOS3 only due to domain:: interfacing

but this fails with a
Program received signal SIGSEGV: Segmentation fault - invalid memory reference.

this appears to demonstrate limitations with XIOS3 handling of UGRID meshes where the coordinates are projection_x & projection_y

@NMannall
Copy link
Collaborator

NMannall commented Oct 7, 2025

Currently, this fails when trying to read coordinate values from the input file. To hit the error when building the mesh, I needed to change the units in planar_mesh.cdl to degrees_east and degrees_north respectively for mesh_node_x, mesh_node_y, mesh_face_x, and mesh_face_y. This is to help investigate the issue, and isn't a suggested change to the demonstration, which, in the long term, we want to use non-latitude and longitude coordinates.

I also had to fix a bug in XIOS3: src/io/netCdf_cf_constant.hpp line 24. The if statement checks XIOS_CF_Longitude_units_.empty() when it should be XIOS_CF_Latitude_units_.empty().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants