is_valid_lineage only checks the lineage object itself. However, the lineage object is completely dependent on the y label mask. This function has been changed to require the y array, and is a much stronger validation of lineages. (Closes #72) This PR changes the is_valid_lineage signature, and should be considered a breaking change.
Additionally, relabel_sequential has been found to map unknown integers to 0. This caused some confusion that the original .trk file had a 0 as a daughter value. When this happens, relabel_sequential_lineage will warn the user that the value is getting mapped to 0. This will only happen with invalid lineages.
Finally, the Track object has been updated to only call relabel_sequential_lineage if the lineage is found to be valid. This should help reduce instantiation time by skipping the relabel step for invalid batches.
is_valid_lineage
only checks the lineage object itself. However, the lineage object is completely dependent on they
label mask. This function has been changed to require they
array, and is a much stronger validation of lineages. (Closes #72) This PR changes theis_valid_lineage
signature, and should be considered a breaking change.Additionally,
relabel_sequential
has been found to map unknown integers to 0. This caused some confusion that the original.trk
file had a 0 as a daughter value. When this happens,relabel_sequential_lineage
will warn the user that the value is getting mapped to 0. This will only happen with invalid lineages.Finally, the
Track
object has been updated to only callrelabel_sequential_lineage
if the lineage is found to be valid. This should help reduce instantiation time by skipping the relabel step for invalid batches.