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

Skip to content

Conversation

oHotel
Copy link
Contributor

@oHotel oHotel commented May 30, 2023

Addition of normalize_axis to ONNXImporter::parseSqueeze to prevent a bug when the attribute axes contains negative values. Negative values are part of the ONNX standard: https://github.com/onnx/onnx/blob/main/docs/Changelog.md#Squeeze-11

Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

  • I agree to contribute to the project under Apache 2 License.
  • To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV
  • The PR is proposed to the proper branch
  • There is a reference to the original bug report and related work
  • There is accuracy test, performance test and test data in opencv_extra repository, if applicable
    Patch to opencv_extra has the same branch name.
  • The feature is well documented and sample code can be built with the project CMake

…egative values for the axes attribut.

Negative values are part of the ONNX optset>=11.

Signed-off-by: Olivier Hotel <[email protected]>
Copy link
Member

@dkurt dkurt left a comment

Choose a reason for hiding this comment

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

Thanks for the contribution! LGTM

@asmorkalov asmorkalov added the category: dnn (onnx) ONNX suport issues in DNN module label May 30, 2023
@asmorkalov asmorkalov added this to the 4.8.0 milestone May 30, 2023
@asmorkalov asmorkalov merged commit c55aee1 into opencv:4.x May 30, 2023
@asmorkalov asmorkalov mentioned this pull request May 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: dnn (onnx) ONNX suport issues in DNN module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants