SegmentationSlice.replace#
- SegmentationSlice.replace(current, new, value=None)[source]#
Create a copy of slice with current segment replaced with new.
- Parameters:
- Raises:
ValueError – If new segment is already in the slice or current segment isn’t.
- Return type: