I think it's a useful feature, but maybe it shouldn't be applied to all cases. For example in an Eady-like set-up, where the domain is horizontally periodic and the velocity has a background gradient this will create discontinuity in x and/or y if the velocity gradient is implemented as a background velocity. So maybe this should be an opt-in feature in the diagnostics.
We already do that in some diagnostics by default like https://github.com/tomchor/Oceanostics.jl/blob/87b29733b0ad25409ec3f5ec3a6b699b9bc38bb8/src/FlowDiagnostics.jl#L95-L111
I think it's a useful feature, but maybe it shouldn't be applied to all cases. For example in an Eady-like set-up, where the domain is horizontally periodic and the velocity has a background gradient this will create discontinuity in x and/or y if the velocity gradient is implemented as a background velocity. So maybe this should be an opt-in feature in the diagnostics.