update for multi-label segmentation