Skip to content

dnn cuda: support Sub#24647

Merged
asmorkalov merged 3 commits intoopencv:4.xfrom
fengyuentau:cuda_sub
Dec 6, 2023
Merged

dnn cuda: support Sub#24647
asmorkalov merged 3 commits intoopencv:4.xfrom
fengyuentau:cuda_sub

Conversation

@fengyuentau
Copy link
Copy Markdown
Member

@fengyuentau fengyuentau commented Dec 5, 2023

Related #24606 (comment)

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

@Abdurrahheem
Copy link
Copy Markdown
Contributor

@fengyuentau the main problem in #24606 and #23977 is that only box prediction on CUDA backed are zeros. There rest of the outputs are exactly the same as on CPU when CUDA backend is used on YOLOv8. You mentioned here that you have not checked if the behaviour is fixed by this PR. So, does this PR really solve the issue?

@fengyuentau
Copy link
Copy Markdown
Member Author

The intention of this PR is to support Sub for CUDA backend. It is a basic operation and needs to be supported.

@asmorkalov asmorkalov merged commit a2edf4d into opencv:4.x Dec 6, 2023
@fengyuentau fengyuentau deleted the cuda_sub branch December 6, 2023 11:44
@Jaxys10
Copy link
Copy Markdown

Jaxys10 commented Dec 8, 2023

按照修改的代码重新cmake试了一下,4.8.0的cpu版本正常,gpu版本框的值还是0,0,0,0。4.7.0版本的opencv,gpu运行的值是正常的。

@fengyuentau
Copy link
Copy Markdown
Member Author

按照修改的代码重新cmake试了一下,4.8.0的cpu版本正常,gpu版本框的值还是0,0,0,0。4.7.0版本的opencv,gpu运行的值是正常的。

So it means something has changed in 4.8.0 that leads to the error. We still need some time to find out why.

@asmorkalov asmorkalov mentioned this pull request Jan 19, 2024
thewoz pushed a commit to thewoz/opencv that referenced this pull request May 29, 2024
dnn cuda: support Sub opencv#24647

Related opencv#24606 (comment)

### Pull Request Readiness Checklist

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

- [x] I agree to contribute to the project under Apache 2 License.
- [x] 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
- [x] The PR is proposed to the proper branch
- [x] There is a reference to the original bug report and related work
- [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable
      Patch to opencv_extra has the same branch name.
- [x] The feature is well documented and sample code can be built with the project CMake
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants