Flexible multi-modal graph-based segmentation