ARTICLE DETAIL

资讯详情

深耕网站视觉设计与运营推广的一线实战洞察。

ultralytics-plus介绍和说明

ultralytics-plus介绍和说明 ultralytics-plus介绍和说明目录ultralytics-plus介绍和说明1. ultralytics介绍2. ultralytics-plus介绍3. 常见错误和解决方法1. RuntimeError: shape [32, 67, -1] is invalid for input of size 2688002. 修复iew size is not compatible with input tensors size and stride1. ultralytics介绍源码https://github.com/ultralytics/ultralyticsUltralytics是一个专注于计算机视觉的开源 AI 库其核心产品是YOLO (You Only Look Once)系列模型如YOLOv8,YOLO11,YOLO26等模型在学术界和工业界都享有盛誉以其卓越的速度、精度和易用性而闻名。Ultralytics 的开源项目是一个功能强大的 AI 视觉平台它集成了多项前沿的计算机视觉任务目标检测 (Object Detection)识别并定位图像或视频中的物体。实例分割 (Instance Segmentation)在像素级精确识别和分离图像中的各个物体。语义分割 (Semantic Segmentation)将图像中的每个像素归类到特定类别。图像分类 (Image Classification)为整个图像分配一个类别标签。姿态估计 (Pose Estimation)检测图像中物体的关键点常用于人体姿态分析。目标跟踪 (Object Tracking)在视频帧序列中持续追踪特定物体的运动轨迹。旋转目标检测 (Oriented Bounding Boxes, OBB)检测带有方向角的目标适用于航拍图像等场景2. ultralytics-plus介绍源码https://github.com/PanJinquan/ultralytics-plusultralytics-plus是在Ultralytics项目基础上增加了支持多种数据格式训练如LablemeCOCO和VOC数据且完全兼容ultralytics仓库。主要特点支持多种数据格式原始ultralytics训练的数据格式主要支持YOLO格式 其他数据集格式需要转换为YOLO格式才能训练ultralytics-plus直接支持Labelme、COCO 和 Pascal VOC等数据格式。支持自定义类别训练原始ultralytics训练数据格式由于采用YOLO格式存在很大局限性如当需要增加或修改类别训练时需要重新生成label标签文件极大不方便。ultralytics-plus直接支持Labelme、COCO 和 Pascal VOC等数据格式用户只需要在配置文件修改names即可直接作用要训练的类别十分方面。完美兼容ultralytics-plus完全兼容官方的ultralytics代码库。用户可以在享受其丰富数据格式支持的同时继续使用ultralytics的所有功能、模型和训练参数无需修改核心工作流。安装方法# 如果已经安装了ultralytics-plus则不需要安装ultralytics # 下载源码ultralytics-plus git clone https://github.com/PanJinquan/ultralytics-plus cd ultralytics-plus # 切换到dev git checkout dev # 如果使用了conda,请激活你的虚拟环境 # conda activate py310 # 激活虚拟环境py310(每次运行都需要运行) pip install . -i https://pypi.tuna.tsinghua.edu.cn/simple # 当安装成功后可以测试ultralytics-plus是否正常训练 yolo detect train datacoco8.yaml modelyolov8n.yaml epochs1 imgsz640 # 会自动下载相关数据进行测试ultralytics-plus已经包含了ultralytics不需要重复安装ultralyticsPython依赖环境使用pip安装即可# Ultralytics requirements # Usage: pip install -r requirements.txt # pip install torch2.2.0 torchvision0.17.0 --index-url https://download.pytorch.org/whl/cpu # Base ---------------------------------------- ultralytics8.0.180 matplotlib3.2.2 numpy1.22.2 # pinned by Snyk to avoid a vulnerability opencv-python4.6.0 pillow7.1.2 pyyaml5.3.1 requests2.23.0 scipy1.4.1 # torch1.8.0 # torchvision0.9.0 tqdm4.64.0 # Logging ------------------------------------- # tensorboard2.13.0 # dvclive2.12.0 # clearml # comet # Plotting ------------------------------------ pandas1.1.4 seaborn0.11.0 # Export -------------------------------------- # coremltools7.0.b1 # CoreML export # onnx1.12.0 # ONNX export # onnxsim0.4.1 # ONNX simplifier # nvidia-pyindex # TensorRT export # nvidia-tensorrt # TensorRT export # scikit-learn0.19.2 # CoreML quantization # tensorflow2.4.1 # TF exports (-cpu, -aarch64, -macos) # tflite-support # tensorflowjs3.9.0 # TF.js export # openvino-dev2023.0 # OpenVINO export # Extras -------------------------------------- psutil # system utilization py-cpuinfo # display CPU info # thop0.1.1 # FLOPs computation # ipython # interactive notebook # albumentations1.0.3 # training augmentations # pycocotools2.0.6 # COCO mAP # roboflow easydict pybaseutils pycocotools toolz3. 常见错误和解决方法1. RuntimeError: shape [32, 67, -1] is invalid for input of size 268800配置文件YOLO task没有对应检测任务taskdetect分割任务tasksegment分类任务taskclassifypose任务taskpose2. 修复iew size is not compatible with input tensors size and strideFile /home/datauser/.conda/envs/py310/lib/python3.10/site-packages/ultralytics/optim/muon.py, line 99, in muon_update m u.view(len(u), -1) if u.ndim 2 else u RuntimeError: view size is not compatible with input tensors size and stride (at least one dimension spans across two contiguous subspaces). Use .reshape(...) instead.Pytorch版本差异问题bash # 原代码 m u.view(len(u), -1) if u.ndim 2 else u # 修改为 m u.reshape(len(u), -1) if u.ndim 2 else u
返回列表