Closed hs2112 closed 1 year ago
Link to file: https://drive.google.com/file/d/1zjbK0nne6AVXtuRvx3qbhwuzbNKeg2er/view?usp=sharing Hope you can take a look.
Could it be because 'hy' variables and dimensions are missing in ea_2005_06_20_00.nc? They got removed when I converted to pressure levels, somehow. Also, they were named differently in my merged file and the ml level column called 'hybrid' did not have its first level mapped to the surface vars -
Hello hs2112,
thanks for sending the bug report!
I checked the netCDF meteo file you shared and fixed some issues with the MPTRAC code:
The old code required the vertical dimension of the netCDF files to be called "lev". The dimension name "plev" only worked under certain circumstances. I revised the code so that it works with both, "lev" and "plev" as the name of the vertical dimension.
In the old code, we assumed the netCDF variable for surface pressure is named "ps" or "PS". Alternatively, if log surface pressure is given, "lnps" or "LNPS" can be provided. I extended the code so that it can also handle the variable names "sp" or "SP" for surface pressure (as in your file).
Previously, we only worked with global meteo data, whereas your test file provides regional data for a lon-lat box. I modified the MPTRAC code a bit so that it can deal with local meteo input data. In the case of local input data, trajectories will be terminated when they leave the given lon-lat box. I tested the feature to some extent, and it seems to work fine, but I recommend carefully checking the model results for your application.
You would have to update to the most recent code version on the master branch, please.
Best regards Lars
Hi @lars2015,
Just moving my comments to the relevant issue.
thanks for the changes. Looks like it's able to read in the 2D variables for the parcel origin file now (issue https://github.com/slcs-jsc/mptrac/issues/13) but it is still not writing the _atm and _grid files for the following timesteps.
My data files are 3 hours apart in time so we are concerned with a 3-hour timestep with files formatted as follows - image
Log file - logfile.log
Run script (run.sh saved as run.txt) - run.txt
Hi @hs2112,
I've added the reply to issue #12.
Best regards Lars
Error (libtrac.c, read_met_grid, l3578): NetCDF: Invalid dimension ID or name