Image segmenation based on region growing in Python using OpenCV