Hi,
I'm looking at expanding the trajectory loader in the name_loaders script. Not to be confused with Iris trajectories, NAME trajectories contain information about the location, age and properties of a Lagrangian particle in the NAME dispersion model. Currently the loader can read in trajectories which have been stored in a single file per particle, so each file contains one particle at multiple time steps.The cube looks like this:
U Turb / (unknown) (time: 385)
Dimension coordinates:
time x
Auxiliary coordinates:
Travel Time x
altitude x
latitude x
longitude x
Scalar coordinates:
PP Index: 1.0
Puff?: N
Release Time: 2016-12-08 16:00:00
Source: Source_1
If we output large numbers of particles we tend to store data as one file per time step so each file contains many particles at one time step. I've created a branch in my fork of Iris (called trajectories_by_time) which loads these files. The cube will look like this:
U Turb / (unknown) (PP Index: 100000)
Dimension coordinates:
PP Index x
Auxiliary coordinates:
Release Time x
Travel Time x
height x
latitude x
longitude x
Scalar coordinates:
Puff?: N
Source: Source AT
time: 2011-03-15 23:00:00
Please correct me if I'm wrong but I think in a true Iris sense I should be thinking of trajectories as a two dimensional cube with "PP Index" and "time" as DimCoords and longitude, latitude, height etc. as two dimensional coordinates. However, I'm not sure how to make this happen in the code. I definitely can't just merge the cubes as I get the following error message:
iris.exceptions.MergeError: failed to merge into a single cube.
Coordinates in cube.aux_coords (non-scalar) differ: Travel Time, height, latitude, longitude.
What is the best way to modify the trajectory_loader so that it is ready for cube merging?
Thank you for your help.
Susan