Skip to content

Issue Loading Custom YOLO Model (.pt) Inside PaddleDetection Environment #9451

@hadasdonat

Description

@hadasdonat

问题确认 Search before asking

  • 我已经搜索过问题,但是没有找到解答。I have searched the question and found no related answer.

请提出你的问题 Please ask your question

’m trying to run the following YOLO command inside my PaddleDetection virtual environment:
(venv310) PS C:\Users\User\MODEL\PaddleDetection> yolo detect predict model="weapons\best.pt" source="C:\Users\User\Videos\CHANCE\DSC04079.JPG" save=True

But I’m getting the following error:
FileNotFoundError: [Errno 2] No such file or directory: 'weapons\best.pt'

The file best.pt does exist at:
C:\Users\User\PaddleDetection\weapons\best.pt

I also tried using the full path, but YOLO still fails to load the model.
My questions are:
1️⃣ Does YOLO need to be executed only from a specific directory (e.g., the official YOLOv8 folder)?
2️⃣ Is it required to place the .pt model file in a specific path inside the environment for it to be detected?
Any guidance on recommended folder structure or best practices for running custom YOLO models inside PaddleDetection would be very helpful.
Thank you! 🙏
Hadas

If you'd like, I can also:
✔ rewrite this message to sound more technical / academic
✔ attach screenshots you choose
✔ create the “YOLO run + custom .pt model setup” guide for your project
Would you like me to prepare that full step-by-step guide now with a professional layout?

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions