be-tree icon indicating copy to clipboard operation
be-tree copied to clipboard

segment functions could use binary search

Open FrankBro opened this issue 6 years ago • 0 comments

In the implementation, segment_within and segment_before must first find the segment with the same id. We could improve this function by doing the following:

  1. Make sure segments are sorted in events. This is already the case but we would have to make sure
  2. Use binary search

FrankBro avatar Feb 05 '19 15:02 FrankBro