[FishBotCamera]3.结合YOLO实现检测
-
@2652794104 日志看起来很奇怪,换台电脑试试可以不可以编译
-
-
@小鱼 谢谢大佬,解决了
-
小鱼,这个用CPU会有点卡,可以用GPU吗,启动时代码改成gpu好像显示只能用cpu或者跳过
-
@2431039560 这个要看yolo那边的了
-
ImportError: cannot import name 'Detect' from 'models.yolo' (/home/jkr/.local/lib/python3.10/site-packages/ultralytics/models/yolo/init.py)
[ros2run]: Process exited with failure 1
ros2 run yolov5_ros2 yolo_detect_2d --ros-args -p device:=cpu -p image_topic:=/fishbot_camera_raw
在输入这段代码后会显示这个错误 -
此回复已被删除! -
@jkr yolo安装问题吧,重装试试
-
@小鱼 重装了一边不太行
-
@小鱼 (1) In PyTorch 2.6, we changed the default value of the
weights_only
argument intorch.load
fromFalse
toTrue
. Re-runningtorch.load
withweights_only
set toFalse
will likely succeed, but it can result in arbitrary code execution. Do it only if you got the file from a trusted source.
(2) Alternatively, to load withweights_only=True
please check the recommended steps in the following error message.
WeightsUnpickler error: Unsupported global: GLOBAL numpy.core.multiarray._reconstruct was not an allowed global by default. Please usetorch.serialization.add_safe_globals([numpy.core.multiarray._reconstruct])
or thetorch.serialization.safe_globals([numpy.core.multiarray._reconstruct])
context manager to allowlist this global if you trust this class/function.
重运行完报这个错