oceanmodeling / xarray-selafin

An xarray engine for opening Selafin files (TELEMAC)
https://pypi.org/project/xarray-selafin/
The Unlicense
4 stars 2 forks source link

fix: fix bug for 3D data inversion #44

Closed tomsail closed 1 month ago

tomsail commented 4 months ago

This PR is to fix issue #43

I had to add the black tools for formatting / linting.

I'll comment below for the on the important changes.

tomsail commented 4 months ago

The fix I provided should work for reading the data.

I just had to reshape for the:

However, since we reshape when read the data, we'd need to reshape when exporting the data too.. And I'm not sure I did my job well there (in selafin.write)

All the tests pass but one: the comparison between the original Selafin and the one we wrote

tomsail commented 1 month ago

I think I have cracked it