Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jun 3, 2025. It is now read-only.

[YOLOv8-Seg] Validation#924

Merged
dbogunowicz merged 18 commits into
mainfrom
feature/damian/yolov8seg_val
Feb 28, 2023
Merged

[YOLOv8-Seg] Validation#924
dbogunowicz merged 18 commits into
mainfrom
feature/damian/yolov8seg_val

Conversation

@dbogunowicz

@dbogunowicz dbogunowicz commented Feb 24, 2023

Copy link
Copy Markdown
Contributor

The validators obey the following hierarchy of inheritance (to reduce the bloating of the codebase):

DeepSparseSegmentationValidator has parents:
- SegmentationValidator (Ultralytics)
- DeepsparseValidator (that handles the main inference method `__call__`)

DeepSparseDetectionValidator has parents:
- DetectionValidator (Ultralytics)
- DeepsparseValidator (that handles the main inference method `__call__`)

adding classification task potentially in the future will be trivial.

Testing plan:

  • Test annotation for YOLO (sanity check)
  • Test annotation for YOLOv8 Det (sanity check)
  • Test annotation for YOLOv8 Seg (sanity check)
  • Test validation for YOLOv8 Det
  • Test validation for YOLOv8 Seg

Validation on yolov8n.onnx reproduces the results reported by the authors:
image
vs

/home/ubuntu/damian/deepsparse_venv/bin/python /home/ubuntu/damian/deepsparse/src/deepsparse/yolov8/validation.py --dataset_yaml coco.yaml --model-path yolov8n-seg.onnx --subtask segmentation 
DeepSparse, Copyright 2021-present / Neuralmagic, Inc. version: 1.4.0.20230211 COMMUNITY | (bacdaef4) (release) (optimized) (system=avx2, binary=avx2)
Ultralytics YOLOv8.0.30 🚀 Python-3.8.10 torch-1.13.1+cu117 CUDA:0 (NVIDIA RTX A4000, 16117MiB)
val: Scanning /home/ubuntu/damian/deepsparse/datasets/coco/labels/val2017.cache... 4952 images, 48 backgrounds, 0 corrupt: 100%|██████████| 5000/5000 [00:00<?, ?it/s]
                 Class     Images  Instances      Box(P          R      mAP50  mAP50-95)     Mask(P          R      mAP50  mAP50-95): 100%|██████████| 313/313 [13:58<00:00,  2.68s/it]
                   all       5000      36335      0.621      0.479      0.516      **0.363**      0.617      0.456      0.489      **0.305**

...

@dbogunowicz dbogunowicz marked this pull request as ready for review February 27, 2023 14:42
@dbogunowicz dbogunowicz changed the base branch from main to feature/damian/cleanupseg1 February 27, 2023 14:49
bfineran
bfineran previously approved these changes Feb 27, 2023

@bfineran bfineran left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - sanity check looks good

KSGulin
KSGulin previously approved these changes Feb 28, 2023

@KSGulin KSGulin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Wanted to note for the casual observer that all commits in this PR were authored by @dbogunowicz and any attributions to me are due to an internal server environment hiccup

Comment thread src/deepsparse/yolov8/utils/validation/segmentation_validator.py
Base automatically changed from feature/damian/cleanupseg1 to main February 28, 2023 12:40
@dbogunowicz dbogunowicz dismissed stale reviews from KSGulin and bfineran via 4750912 February 28, 2023 12:40
Comment thread src/deepsparse/yolov8/utils/validation/deepsparse_validator.py
@dbogunowicz dbogunowicz merged commit c0df30e into main Feb 28, 2023
@dbogunowicz dbogunowicz deleted the feature/damian/yolov8seg_val branch February 28, 2023 13:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants