Connected-components labeling set-up.
Merge branch 'algorithms' of https://github.com/skytreader/sandbox into algorithms