0-1 graph partitioning and image segmentation