Open Builder-Byte opened 1 month ago
👋 Hello @Builder-Byte, thank you for your interest in Ultralytics YOLOv8 🚀! We recommend a visit to the Docs for new users where you can find many Python and CLI usage examples and where many of the most common questions may already be answered.
If this is a 🐛 Bug Report, please provide a minimum reproducible example to help us debug it.
If this is a custom training ❓ Question, please provide as much information as possible, including dataset image examples and training logs, and verify you are following our Tips for Best Training Results.
Join the vibrant Ultralytics Discord 🎧 community for real-time conversations and collaborations. This platform offers a perfect space to inquire, showcase your work, and connect with fellow Ultralytics users.
Pip install the ultralytics
package including all requirements in a Python>=3.8 environment with PyTorch>=1.8.
pip install ultralytics
YOLOv8 may be run in any of the following up-to-date verified environments (with all dependencies including CUDA/CUDNN, Python and PyTorch preinstalled):
If this badge is green, all Ultralytics CI tests are currently passing. CI tests verify correct operation of all YOLOv8 Modes and Tasks on macOS, Windows, and Ubuntu every 24 hours and on every commit.
Probably need to update your OpenCV version
Thank you for your suggestion! Updating OpenCV can indeed resolve compatibility issues. To update OpenCV, you can use the following command:
pip install --upgrade opencv-python
Additionally, ensure that your ONNX model is exported correctly. You can use the following Python script to export your YOLOv8 model to ONNX format:
from ultralytics import YOLO
# Load a model
model = YOLO("yolov8s.pt")
# Export the model to ONNX format
model.export(format="onnx", opset=12, simplify=True)
If the issue persists, please provide a minimal reproducible example to help us diagnose the problem more effectively. You can refer to our Minimum Reproducible Example guide for more details.
Feel free to reach out if you have any further questions! 😊
👋 Hello there! We wanted to give you a friendly reminder that this issue has not had any recent activity and may be closed soon, but don't worry - you can always reopen it if needed. If you still have any questions or concerns, please feel free to let us know how we can help.
For additional resources and information, please see the links below:
Feel free to inform us of any other issues you discover or feature requests that come to mind in the future. Pull Requests (PRs) are also always welcomed!
Thank you for your contributions to YOLO 🚀 and Vision AI ⭐
Search before asking
YOLOv8 Component
Other
Bug
error after executing make https://github.com/ultralytics/ultralytics/tree/main/examples/YOLOv8-CPP-Inference voldy@Divyansh:~/ultralytics/examples/YOLOv8-CPP-Inference/build$ ./Yolov8CPPInference
terminate called after throwing an instance of 'cv::Exception' what(): OpenCV(4.5.4) ./modules/dnn/src/onnx/onnx_importer.cpp:739: error: (-2:Unspecified error) in function 'handleNode'
Environment
Ultralytics YOLOv8.2.54 🚀 Python-3.10.12 torch-2.3.1+cu121 CPU (Intel Core(TM) Ultra 5 125H) Setup complete ✅ (18 CPUs, 7.6 GB RAM, 64.7/1006.9 GB disk)
OS Linux-5.15.153.1-microsoft-standard-WSL2-x86_64-with-glibc2.35 Environment Linux Python 3.10.12 Install pip RAM 7.57 GB CPU Intel Core(TM) Ultra 5 125H CUDA None
numpy ✅ 1.23.5<2.0.0,>=1.23.0 matplotlib ✅ 3.9.1>=3.3.0 opencv-python ✅ 4.10.0.84>=4.6.0 pillow ✅ 10.4.0>=7.1.2 pyyaml ✅ 6.0.1>=5.3.1 requests ✅ 2.32.3>=2.23.0 scipy ✅ 1.14.0>=1.4.1 torch ✅ 2.3.1>=1.8.0 torchvision ✅ 0.18.1>=0.9.0 tqdm ✅ 4.66.4>=4.64.0 psutil ✅ 6.0.0 py-cpuinfo ✅ 9.0.0 pandas ✅ 2.2.2>=1.1.4 seaborn ✅ 0.13.2>=0.11.0 ultralytics-thop ✅ 2.0.0>=2.0.0
Minimal Reproducible Example
include
include
include
include <opencv2/opencv.hpp>
include "inference.h"
using namespace std; using namespace cv;
int main(int argc, char **argv) { std::string projectBasePath = "/home/voldy/ultralytics"; // Set your ultralytics base path bool runOnGPU = false;
}
Additional
No response
Are you willing to submit a PR?