I'm pretty sure calling LinearIndices on a BorderArray should return indices in the same format as calling LinearIndices on an OffsetArray, but that's not the case. This seems to be because axes() returns generic range objects for BorderArrays while it returns IdentityUnitRanges for OffsetArrays, and LinearIndices only gives the correct answer with IdentityUnitRanges. I have a fix, will make a PR.
using ImageFiltering, OffsetArrays
b = BorderArray(zeros(10), Fill(1.0, (3,), (0,)))
all(LinearIndices(b) .== LinearIndices(OffsetArray(zeros(13), -3))) # false, should be true
I'm pretty sure calling LinearIndices on a BorderArray should return indices in the same format as calling LinearIndices on an OffsetArray, but that's not the case. This seems to be because axes() returns generic range objects for BorderArrays while it returns IdentityUnitRanges for OffsetArrays, and LinearIndices only gives the correct answer with IdentityUnitRanges. I have a fix, will make a PR.