Fix PYRE_MISSING_ANNOTATIONS issues in fbcode/deeplearning/projects/sam3_release/sam3/model/io_utils.py

Differential Revision: D104574586

fbshipit-source-id: 9492a0033999987f381fe83ef198ebc315f92217
This commit is contained in:
generatedunixname1401739305002972
2026-05-10 11:10:07 -07:00
committed by meta-codesync[bot]
parent 8d01d6ce78
commit 4bf4a8aaff
+2 -2
View File
@@ -726,10 +726,10 @@ class AsyncVideoFileLoaderWithTorchCodec:
raise RuntimeError(f"Failed to load frame {index} after {max_tries} tries")
def __len__(self):
def __len__(self) -> int:
return len(self.images)
def __getstate__(self):
def __getstate__(self) -> dict[str, Any]:
"""
Remove a few attributes during pickling, so that this async video loader can be
saved and loaded as a part of the model session.