https://github.com/GRSEB9S/roipoly.py could be useful for the polygon masking on the images. If so, we'll consider adding some part of it to openpiv-python to handle complex masks.