Shua-Kang / ros_pytorch_yolov5

23 stars 8 forks source link

I can run yolov5s.pt but if I want to change weights I take this error #5

Closed hasantokatlioglu closed 2 years ago

hasantokatlioglu commented 2 years ago

error

Shua-Kang commented 2 years ago

This repository uses v5.0 version of yolov5, you may be using the latest 6.1 or other versions. Two ways

  1. Use yolov5 v5.0 to train your model. Find v5.0 version from release. https://github.com/ultralytics/yolov5/releases
  2. Update yolov5 of this repo to the version you are using.
hasantokatlioglu commented 2 years ago

when I was training, I used yolov5x.pt

Shua-Kang commented 2 years ago

It needs to replace the file from yolov5 of this repo. From your screenshot, I think you can try to replace ros_pytorch_yolov5/yolov5/models/common.py with your_yolov5/models/common.py. And after replacement, if it gets new error from other files, just replace them with yours.

hasantokatlioglu commented 2 years ago

Thank you

Shua-Kang commented 2 years ago

@hasantokatlioglu Yolov5 v6.1 has been updated at branch v6.1. https://github.com/Shua-Kang/ros_pytorch_yolov5/tree/v6.1