testing pair correlation on binary image