You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently da.map_overlap supports edge paddings of different kinds along different dimensions. This complicates things like using da.pad within da.map_overlap.
AFAIK there are no use cases for different edge paddings on different dimensions. The closest thing that I know of is to pad some dimensions and not others (i.e. having different depths per dimension), which can still be cast in terms of having the same padding for all dimensions (just some are trivial). Given this, I'd like to propose deprecating boundary arguments that are anything other than simple values (e.g. padding mode or constant for all dimensions).
One hypothetical case that comes to mind is solving PDEs, where having
different boundary conditions on different edges is quite common. I know
people that have tried using Dask for this, but given up due to poor
performance. I don't have a good way to determine how important this
feature is.
Good point. Though these would still be possible by applying da.pad repeatedly with the intended padding before calling da.map_overlap.
Should add that my general inclination is actually to push all users looking for explicit padding from Dask to use da.pad instead of relying on da.map_overlap to support this behavior directly. Often functions (at least in the image processing domain) do some implicit padding internally anyways.
I think I prefer to have a convenience keyword argument in map_overlap. I'd be more than happy if that called pad. I don't care strongly about different edge paddings on different dimensions.
In terms of handling this before 2.0 I don't have strong thoughts. To me this doesn't seem to be a large priority to me personally (I haven't heard anyone complain) and so I don't think that it should block release.
Activity
[-]Simplifying da.map_overlap's overlaps[/-][+]Simplifying da.map_overlap's boundary padding[/+]mrocklin commentedon Nov 27, 2018
jakirkham commentedon Nov 27, 2018
Good point. Though these would still be possible by applying
da.padrepeatedly with the intended padding before callingda.map_overlap.Should add that my general inclination is actually to push all users looking for explicit padding from Dask to use
da.padinstead of relying onda.map_overlapto support this behavior directly. Often functions (at least in the image processing domain) do some implicit padding internally anyways.jakirkham commentedon Jun 20, 2019
Thoughts on handling this in 2.0?
xref: #4973
mrocklin commentedon Jun 21, 2019
I think I prefer to have a convenience keyword argument in map_overlap. I'd be more than happy if that called pad. I don't care strongly about different edge paddings on different dimensions.
In terms of handling this before 2.0 I don't have strong thoughts. To me this doesn't seem to be a large priority to me personally (I haven't heard anyone complain) and so I don't think that it should block release.