im1mask in lucasKanade
In lucasKanade
: im1
moves and im2
is fixed.
However we never move im1mask
.
Are these lines L280(287):
if im1mask is not None:
im1defCrop[im1mask[crop1] == False] = numpy.nan
correct?
Maybe the way to go to avoid correlating zones we don't want is to define a fixed mask in im2 and lines L338:
DICToolkit.computeDICoperators(im2crop,
im1defCrop,
im2gradZ[crop2],
im2gradY[crop2],
im2gradX[crop2], M, A)
become:
DICToolkit.computeDICoperators(im2cropMasked,
im1defCropForgetMask,
im2gradZ[crop2],
im2gradY[crop2],
im2gradX[crop2], M, A)
Edited by Olga Stamati