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

OTX D-Fine Detection Algorithm Integration #4142

Merged
merged 95 commits into from
Jan 17, 2025

Conversation

eugene123tw
Copy link
Collaborator

@eugene123tw eugene123tw commented Dec 4, 2024

Summary

OTX D-Fine Detection Algorithm Integration: https://github.com/Peterande/D-FINE

  • Introduced five variants of the D-Fine detection algorithm.
  • Integrated the HGNetv2 backbone from PaddleDetection.
  • Cleaned and optimized the original codebase by:
    • Reducing code duplication where possible.
    • Adding docstrings for all methods and functions.
    • Benchmarking OpenVINO/PyTorch detection results for accuracy and performance.

Cross-Reference Comparison

Geti DFine-X OTX DFine-X
BlueBerry 88% 88%
Vitens Coliform 56% 48%
Vitens Coliform (Tiling) 86% 74%
Vitens Aeromonas 92% 94%
WGISD 80% 86%

Next phase

  • Validate potential module combinations that could be unified in future iterations, such as:
    • D-Fine Decoder and RT-DETR Decoder.
    • D-Fine Hybrid Encoder and RT-DETR Decoder.
    • D-Fine Criterion and RT-DETR Criterion.
  • Validate Post-Training Optimization Tool (POT) results and assess potential accuracy drops.
  • Validate XAI feature.

How to test

  • otx train --config src/otx/recipe/detection/dfine_x.yaml --data_root DATA_ROOT
  • pytest tests/unit/algo/detection/test_dfine.py

Checklist

  • I have added unit tests to cover my changes.​
  • I have added integration tests to cover my changes.​
  • I have ran e2e tests and there is no issues.
  • I have added the description of my changes into CHANGELOG in my target branch (e.g., CHANGELOG in develop).​
  • I have updated the documentation in my target branch accordingly (e.g., documentation in develop).
  • I have linked related issues.

License

  • I submit my code changes under the same Apache License that covers the project.
    Feel free to contact the maintainers if that's a concern.
  • I have updated the license header for each file (see an example below).
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

@eugene123tw eugene123tw requested review from kprokofi, samet-akcay and sovrasov and removed request for kprokofi January 14, 2025 18:35
Daankrol
Daankrol previously approved these changes Jan 17, 2025
Copy link
Collaborator

@Daankrol Daankrol left a comment

Choose a reason for hiding this comment

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

Looks really good! Some very small notes, can be merged if tests are fixed.

…imizer configuration documentation; change reg_scale to float in DFINETransformer.
@sovrasov sovrasov merged commit d663fd7 into openvinotoolkit:develop Jan 17, 2025
22 of 23 checks passed
@eugene123tw eugene123tw deleted the eugene/d-fine-poc branch January 17, 2025 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BUILD DEPENDENCY Any changes in any dependencies (new dep or its version) should be produced via Change Request on PM DOC Improvements or additions to documentation TEST Any changes in tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants