Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor release preparation. #93

Merged
merged 8 commits into from
Oct 4, 2024
Merged

Minor release preparation. #93

merged 8 commits into from
Oct 4, 2024

Conversation

kkeroo
Copy link
Collaborator

@kkeroo kkeroo commented Oct 2, 2024

In this PR we add support in examples for unsupported parsers including:

  • MultiClassificationParser
  • PaddleOCRParser
  • PPTextDetectionParser
  • XFeat Mono and Stereo parsers

XFeat example is a bit different so it is not implemented in the general example flow but its rather in its own function.

Next, I extended the MultiClassificationParser because it didnt have set methods. I also increased the tolerance in probability scores validation - if the scores sum to 1. The problem was with efficientnet-lite becuase it predicts 1000 classes so sometimes it didnt meet the criteria (maybe rounding errors or something?).

I adjusted Segmentation and Keypoint parsers so the warning (Expected 1 output layer, got .... Taking the first one) is not spammed in real time but rather only printed once.

@github-actions github-actions bot added the parsers Changes affecting ml.parsers label Oct 2, 2024
Copy link

github-actions bot commented Oct 2, 2024

Test Results

143 tests   143 ✅  1s ⏱️
  1 suites    0 💤
  1 files      0 ❌

Results for commit a0d2ef7.

♻️ This comment has been updated with latest results.

Copy link

github-actions bot commented Oct 2, 2024

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
2458 972 40% 0% 🟢

New Files

No new covered files...

Modified Files

File Coverage Status
depthai_nodes/ml/messages/creators/classification.py 98% 🟢
depthai_nodes/ml/parsers/classification.py 21% 🟢
depthai_nodes/ml/parsers/keypoints.py 22% 🟢
depthai_nodes/ml/parsers/segmentation.py 19% 🟢
TOTAL 40% 🟢

updated for commit: a0d2ef7 by action🐍

@kkeroo kkeroo added messages Changes affecting ml.messages examples Changes affecting examples. tests Changes affecting tests labels Oct 2, 2024
@kkeroo kkeroo marked this pull request as ready for review October 3, 2024 08:28
Copy link
Contributor

@aljazkonec1 aljazkonec1 left a comment

Choose a reason for hiding this comment

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

Looks good, added small comment for xfeat example

Copy link
Collaborator

@jkbmrz jkbmrz left a comment

Choose a reason for hiding this comment

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

LGTM, just two small docstring comments

depthai_nodes/ml/parsers/keypoints.py Show resolved Hide resolved
depthai_nodes/ml/parsers/segmentation.py Show resolved Hide resolved
@kkeroo kkeroo merged commit 3f3e360 into dev Oct 4, 2024
11 checks passed
@kkeroo kkeroo deleted the release/prepare branch October 4, 2024 06:04
klemen1999 added a commit that referenced this pull request Oct 7, 2024
* Added labeler to CI (#43)

* Updated requirements.txt (#44)

* Added coverage badge to README (#45)

* Added package version (#46)

* Update ci.yaml

* [Automated] Updated coverage badge

* Update README.md

* YOLOv8 kpts and seg example. (#48)

* Extend MPPalmDetection parser. (#49)

* Add support for different input sizes.

* Support extended palm detection in examples.

* Pre-commit fix.

* Add normalization.

* feat: add support for metric depth

* fix: broken depth tests

* fix: pre-commit

* fix: change default depth limit to float

* feat: add test for metric depth map

* Developer guide docs added. (#51)

* Support for metrics depth type. (#52)

* Hotfix: remove no-commit from pre-commit (#54)

* Added automatic PyPI publishing (#55)

* feat: add parser for DM-Count crowd density estimation model

* fix: pre-commit

* fix: add missing imports

* feat: add property methods to Map2D message

* fix: density map dimensions

* fix: pre-commit

* feat: unify map parsers

* feat: unify map message creators

* refactor: simplify map message file name

* feat: add map tests

* fix: pre-commit

* fix: map tests

* fix: map scaling test

* fix: pre-commit

* [Automated] Updated coverage badge

* feat: remove thermal image parser and creator

* feat: remove thermal image tests

* fix: remove imports of the deleted objects

* [Automated] Updated coverage badge

* fix: create_map_message output type hint

* fix: pre-commit

* Adds FastSAM to example. (#58)

* Extend Segmentation Parser. (#59)

* Extend input shapes options.

* Small fix.

* Added PaddlePaddle Text detection model parser.

* Added Parser to __init__

* Fixes Shape Error bug

* pre-commit error

* [fix] precommit

* [Automated] Updated coverage badge

* Revision.

* Remove syntax error

Co-authored-by: KlemenSkrlj <47853619+klemen1999@users.noreply.github.com>

* Update depthai_nodes/ml/parsers/utils/ppocr.py

* Renamed some functions.

* Removed wrong  __init__ imports

* PaddleOCR model returns a sequence of classification probabilities for characters.

This PR adds a classification_sequence_message that returns a sequence of charecters corresponding to maximum probability in the sequence.
The message has optional parameters to remove duplicates and ignore background class indexes.

In addition this PR also adds a PaddleOCR Parser, which utilizes the classification_sequence message.

* [Automated] Updated coverage badge

* Lane detection parser. (#61)

* Add LaneDetectionParser.

* Add tests.

* Add LaneDetection parser to parsers.

* Example added.

* typo.

* Precommit fix.

* [Automated] Updated coverage badge

---------

Co-authored-by: GitHub Actions <actions@github.com>

* [Automated] Updated coverage badge

* PaddleOCR Parser and Classification Sequence message

* Added unit tests and modified some assertions

* pre-commit fixs

* Doc string fix

* [Automated] Updated coverage badge

* small fix

* [BUG] small bug fix where x_min was not <= x_max

* Added VehicleAttribte Parser and tests.

* Added docstrings.

* [Automated] Updated coverage badge

* Changed to MultiClassification parser

* [Automated] Updated coverage badge

* Updated docstrings and names

* fixed unit-test name

* Updated variable names.

* Refactor code.

* remove AgeGender Message.

* Refactor examples.

* refactor: separate visualizers and their utils

* refactor: remove mapping.py

* feat: add support for models with 2D map output

* fix: add FPS limit to avoid OAK-D Lite errors

* docs: update README.md

* fix: pre-commit

* [HOT-FIX] Update ppdet to return polygons.

* [Automated] Updated coverage badge

* Update depthai_nodes/ml/parsers/ppdet.py

Co-authored-by: KlemenSkrlj <47853619+klemen1999@users.noreply.github.com>

* dele one line

* Better error in MPPalmDetectionParser. (#72)

* Fix RVC4 order (#76)

* XFeat parser for Mono and Stereo. (#82)

* Tiling and TilesPatcher (#89)

* Release depthai-nodes v0.0.1 (#53)

* Added labeler to CI (#43)

* Updated requirements.txt (#44)

* Added coverage badge to README (#45)

* Added package version (#46)

* Update ci.yaml

* [Automated] Updated coverage badge

* Update README.md

* YOLOv8 kpts and seg example. (#48)

* Extend MPPalmDetection parser. (#49)

* Add support for different input sizes.

* Support extended palm detection in examples.

* Pre-commit fix.

* Add normalization.

* feat: add support for metric depth

* fix: broken depth tests

* fix: pre-commit

* fix: change default depth limit to float

* feat: add test for metric depth map

* Developer guide docs added. (#51)

* Support for metrics depth type. (#52)

* Hotfix: remove no-commit from pre-commit (#54)

* Added automatic PyPI publishing (#55)

---------

Co-authored-by: Martin Kozlovský <kozlovsky.m7@gmail.com>
Co-authored-by: GitHub Actions <actions@github.com>
Co-authored-by: Jaša Kerec <61207502+kkeroo@users.noreply.github.com>
Co-authored-by: jkbmrz <jakob.mraz@gmail.com>
Co-authored-by: jkbmrz <74824974+jkbmrz@users.noreply.github.com>

* initial commit with two nodes - Tiling and TilesPatcher | TilesPatcher implemented to work with dai.ImgDetections

* running pre-commit

* refactored locations of nodes into helpers + docstring added

---------

Co-authored-by: KlemenSkrlj <47853619+klemen1999@users.noreply.github.com>
Co-authored-by: Martin Kozlovský <kozlovsky.m7@gmail.com>
Co-authored-by: GitHub Actions <actions@github.com>
Co-authored-by: Jaša Kerec <61207502+kkeroo@users.noreply.github.com>
Co-authored-by: jkbmrz <jakob.mraz@gmail.com>
Co-authored-by: jkbmrz <74824974+jkbmrz@users.noreply.github.com>

* reformatted docstring in epytext (#92)

* reformatted docstring in epytext

* [Automated] Updated coverage badge

---------

Co-authored-by: GitHub Actions <actions@github.com>

* Minor release preparation. (#93)

* Bigger tolerance for classification scores.

* Improved MultiClassificationParser.

* Warnings in Keypoints and Segmentation parsers.

* Examples for new models.

* Adjusted tests due to tolerance change.

* Add XFeat Mono and Stereo to examples.

* XFeat demo instructions.

* Remove warp drawing in stereo mode.

* Version bump. (#97)

* Release: Fix merge conflicts (#99)

---------

Co-authored-by: Martin Kozlovský <kozlovsky.m7@gmail.com>
Co-authored-by: GitHub Actions <actions@github.com>
Co-authored-by: Jaša Kerec <61207502+kkeroo@users.noreply.github.com>
Co-authored-by: jkbmrz <jakob.mraz@gmail.com>
Co-authored-by: jkbmrz <74824974+jkbmrz@users.noreply.github.com>
Co-authored-by: aljazkonec1 <konec.aljaz1@gmail.com>
Co-authored-by: aljazkonec1 <53098513+aljazkonec1@users.noreply.github.com>
Co-authored-by: Jan Čuhel <79118988+HonzaCuhel@users.noreply.github.com>
Co-authored-by: Han Bui <74987252+spbui00@users.noreply.github.com>
klemen1999 pushed a commit that referenced this pull request Oct 24, 2024
* Bigger tolerance for classification scores.

* Improved MultiClassificationParser.

* Warnings in Keypoints and Segmentation parsers.

* Examples for new models.

* Adjusted tests due to tolerance change.

* Add XFeat Mono and Stereo to examples.

* XFeat demo instructions.

* Remove warp drawing in stereo mode.
klemen1999 pushed a commit that referenced this pull request Oct 24, 2024
* Bigger tolerance for classification scores.

* Improved MultiClassificationParser.

* Warnings in Keypoints and Segmentation parsers.

* Examples for new models.

* Adjusted tests due to tolerance change.

* Add XFeat Mono and Stereo to examples.

* XFeat demo instructions.

* Remove warp drawing in stereo mode.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
examples Changes affecting examples. messages Changes affecting ml.messages parsers Changes affecting ml.parsers tests Changes affecting tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants