https://github.com/uwmisl/poretitioner/blob/6e6ad462066d583b4dd198f7804d8d6018b2d903/src/poretitioner/utils/segment.py#L402-L402