Skip to content

Commit

Permalink
Additional comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Diamond committed Oct 4, 2023
1 parent c9b2d81 commit cd89505
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions python/fusion_engine_client/parsers/fast_indexer.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,13 @@ def _search_blocks_for_fe(input_path: str, block_starts: List[int]):

num_syncs += len(sync_matches)

# To do the CRC check and find a p1_time the full message needs to be parsed.
# To do the CRC check and find a p1_time the full message needs to be parsed. This
# section is not particularly optimized. The chance of the preamble appearing in data
# is relatively low, so this code is in a much less hot path then the preamble sync above.
for i in sync_matches:
absolute_offset = i + block_offset
# Don't check preambles found inside other valid messages.
# Don't check preambles found inside other valid messages. Generally, this didn't
# provide much speed up, but could prevent wasting cycles if the message size is large.
if absolute_offset < message_end:
continue

Expand Down

0 comments on commit cd89505

Please sign in to comment.