|
|
@ -159,7 +159,7 @@ class FrameReader: |
|
|
|
self.it: Iterator[tuple[int, np.ndarray]] | None = None |
|
|
|
self.it: Iterator[tuple[int, np.ndarray]] | None = None |
|
|
|
self.fidx = -1 |
|
|
|
self.fidx = -1 |
|
|
|
|
|
|
|
|
|
|
|
def get(self, fidx:int) -> list[np.ndarray]: |
|
|
|
def get(self, fidx:int) -> np.ndarray: |
|
|
|
if fidx in self._cache: # If frame is cached, return it |
|
|
|
if fidx in self._cache: # If frame is cached, return it |
|
|
|
return self._cache[fidx] |
|
|
|
return self._cache[fidx] |
|
|
|
read_start = self.decoder.get_gop_start(fidx) |
|
|
|
read_start = self.decoder.get_gop_start(fidx) |
|
|
|