Fast, optimized ‘for’ pixel loops with OpenCV and Python