pooya-mohammadi / yolov5-gradcam

Visualizing Yolov5's layers using GradCam

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

RuntimeError: don't know how to restore data location of torch.HalfStorage (tagged with )

YTTT9 opened this issue · comments

commented

D:\anaconda\envs\yolov5\lib\site-packages\deep_utils\vision\face_detection\ultralight_init_.py:3: UserWarning:
No module named 'deep_utils.vision.face_detection.ultralight.torch'. If you don't use UltralightTorchFaceDetector ignore this message.
UltralightTorchFaceDetector = import_module(
D:\anaconda\envs\yolov5\lib\site-packages\deep_utils\vision\face_detection\ultralight_init_.py:6: UserWarning:
No module named 'deep_utils.vision.face_detection.ultralight.tf'. If you don't use UltralightTFFaceDetector ignore this message.
UltralightTFFaceDetector = import_module(
D:\anaconda\envs\yolov5\lib\site-packages\deep_utils\callbacks\tf_keras_init_.py:3: UserWarning:
No module named 'tensorflow'. If you don't use LRScalar ignore this message.
LRScalar = import_module(
[INFO] Loading the model
Traceback (most recent call last):
File "main.py", line 125, in
main(args.img_path)
File "main.py", line 64, in main
model = YOLOV5TorchObjectDetector(args.model_path, device, img_size=input_size,
File "D:\AAAAAAAAA\YOLOV5-4.0\yolov5-gradcam-master\models\yolo_v5_object_detector.py", line 32, in init
self.model = attempt_load(model_weight, device=device)
File "D:\AAAAAAAAA\YOLOV5-4.0\yolov5-gradcam-master\models\experimental.py", line 80, in attempt_load
ckpt = torch.load(attempt_download(w), map_location=device)
File "D:\anaconda\envs\yolov5\lib\site-packages\torch\serialization.py", line 594, in load
return _load(opened_zipfile, map_location, pickle_module, **pickle_load_args)
File "D:\anaconda\envs\yolov5\lib\site-packages\torch\serialization.py", line 853, in _load
result = unpickler.load()
File "D:\anaconda\envs\yolov5\lib\site-packages\torch\serialization.py", line 845, in persistent_load
load_tensor(data_type, size, key, _maybe_decode_ascii(location))
File "D:\anaconda\envs\yolov5\lib\site-packages\torch\serialization.py", line 834, in load_tensor
loaded_storages[key] = restore_location(storage, location)
File "D:\anaconda\envs\yolov5\lib\site-packages\torch\serialization.py", line 811, in restore_location
return default_restore_location(storage, map_location)
File "D:\anaconda\envs\yolov5\lib\site-packages\torch\serialization.py", line 178, in default_restore_location
raise RuntimeError("don't know how to restore data location of "
RuntimeError: don't know how to restore data location of torch.HalfStorage (tagged with )

@YTTT9
The issue is solved

@YTTT9 The issue is solved

Hello, how did you solve this problem? I met this problem elsewhere.