refactor(main.py): update video preloading comment to reflect new approach and improve readability
This commit is contained in:
4
main.py
4
main.py
@@ -529,14 +529,14 @@ class MediaGrader:
|
||||
self.segment_current_frames[i] = start_frame # Start each segment at its position
|
||||
print(f"Segment positions: {self.segment_positions}")
|
||||
|
||||
# Preload the entire video into memory with threaded I/O
|
||||
# Preload the entire video into memory - simple and fast
|
||||
print("Preloading entire video into memory...")
|
||||
preload_start = time.time()
|
||||
|
||||
if self.current_cap and self.current_cap.isOpened():
|
||||
self.current_cap.set(cv2.CAP_PROP_POS_FRAMES, 0)
|
||||
|
||||
# Read all frames in one shot - let OpenCV and OS handle buffering
|
||||
# Simple, fast sequential read
|
||||
frames = []
|
||||
frame_count = 0
|
||||
|
||||
|
Reference in New Issue
Block a user