Allows DatasetRestoring to act on fields by different name#199
Conversation
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
|
I don't think we can pass a varname that is different than the one in metadata, while this keyword argument would allow it. I would probably drop the variable_name kwarg, what you want to achieve can be done just by passing |
Oh yes thats true |
Co-authored-by: Simone Silvestri <silvestri.simone0@gmail.com>
|
Could I add a scale factor to the dataset? Do you think it would be best to do it in the constructor, or to pass a scale factor to the forcing function? |
Since 0.3.0 can't build FTS of ECCO Darwin variables as their location isn't in the ECCO_location dictionary
|
there is already the |
I mean if the dataset is different (e.g. in different units) to the field its restoring, so it would go in as s in |
|
We have a |
Doesn't that do a fixed conversion depending on the dataset? Or is the a user way to change the conversion? |
|
Circling back to this issue: I think it would be good if users could pass a "conversion unit" to |
|
The units system is a bit rough around the edges. @bgroenks96 proposed refactoring it using https://github.com/JuliaPhysics/Unitful.jl.
For physics quantities we probably do not want to change the units because the interface fluxes enforce a certain convention (temperature in kelvin, salinity in psu, velocities in m/s and so on). I can imagine that for tracers each model might want to have its own convention. We will need to enforce some type of consistency with what the flux solver sees though. |
I saw this which seems like a good idea but a lot of work.
Yeah that makes sense r.e. physical quantities. People use different units for different BGC models (e.g. mol C vs mol N) so I think theres going to frequently be cases where you might want to change units for restoring, but thats going to make a challenge to enforce correct units when necessary for fluxes. Could I merge this PR and open a new one to think about that? |
This PR moves
variable_nameto be akwarginDatasetRestoringto allow users to override the default naming.Also closes #61