Skip to content

Commit

Permalink
fix finding next closest keyframe logic
Browse files Browse the repository at this point in the history
Signed-off-by: Shunsuke Miura <[email protected]>
  • Loading branch information
miursh committed Nov 23, 2023
1 parent 8e017c0 commit 084ea1e
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import argparse
import json
import os.path as osp
from pathlib import Path


Expand Down Expand Up @@ -201,6 +202,8 @@ def _get_next_closest_keyframe(self, current_sample_data: dict, sample_data_list
if sample_data["is_key_frame"]
and sample_data["timestamp"] > timestamp
and sample_data["fileformat"] == current_sample_data["fileformat"]
and osp.dirname(sample_data["filename"])
== osp.dirname(current_sample_data["filename"])
]
for sample_data in sample_data_keyframe_list:
if sample_data["timestamp"] < next_closest_keyframe["timestamp"]:
Expand Down

0 comments on commit 084ea1e

Please sign in to comment.