rPPG icon indicating copy to clipboard operation
rPPG copied to clipboard

_pickle.UnpicklingError: invalid load key, 'v'. on Ubuntu 22.04

Open snowuyl opened this issue 2 years ago • 3 comments

Downloading: "https://download.pytorch.org/models/resnet34-b627a593.pth" to /home/snowuyl/.cache/torch/hub/checkpoints/resnet34-b627a593.pth 100.0% Traceback (most recent call last): File "/home/snowuyl/samba/workspace_Python/rPPG/run.py", line 65, in runPOS(source) File "/home/snowuyl/samba/workspace_Python/rPPG/run.py", line 39, in call capture = CaptureFrames(self.batch_size, source, show_mask=True) File "/home/snowuyl/samba/workspace_Python/rPPG/capture_frames.py", line 20, in init self.model.load_state_dict(torch.load('linknet.pth')) File "/home/snowuyl/.local/lib/python3.10/site-packages/torch/serialization.py", line 713, in load return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args) File "/home/snowuyl/.local/lib/python3.10/site-packages/torch/serialization.py", line 920, in _legacy_load magic_number = pickle_module.load(f, **pickle_load_args) _pickle.UnpicklingError: invalid load key, 'v'.

snowuyl avatar Sep 30 '22 03:09 snowuyl

I resolve this issue by downloading the file using git lfs, you can remove linknet.pth, and run: git lfs install, git lfs pull

aljasser avatar Oct 21 '22 15:10 aljasser

What file is git lfs and where to download it

Magicyp avatar Nov 07 '22 03:11 Magicyp

I resolve this issue by downloading the file using git lfs, you can remove linknet.pth, and run: git lfs install, git lfs pull

#:git lfs pull Git LFS: (0 of 1 files) 0 B / 83.27 MB
batch response: Post https://github.com/nasir6/rPPG.git/info/lfs/objects/batch: dial tcp 20.205.243.166:443: getsockopt: connection refused error: failed to fetch some objects from 'https://github.com/nasir6/rPPG.git/info/lfs'

Hello I also encountered this error, try your method, encountered the above error, it seems that the git lfs website is not connected

burn-gif avatar Nov 15 '23 08:11 burn-gif