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

Skip to content

Conversation

@mshabunin
Copy link
Contributor

Merge with opencv/opencv_contrib#3642

  • Removed obsolete apps - traincascade and createsamples (please use older OpenCV versions if you need them). These apps relied heavily on C-API
  • removed all mentions of imgproc C-API headers (imgproc_c.h, types_c.h) - they were empty, included core C-API headers
  • replaced usage of several C constants with C++ ones (error codes, norm modes, RNG modes, PCA modes, ...) - most part of this PR (split into two parts - all modules and calib+3d - for easier backporting)
  • removed imgproc C-API headers (as separate commit, so that other changes could be backported to 4.x)

Most of these changes can be backported to 4.x.

@asmorkalov
Copy link
Contributor

Looks good to me! Please fix compiler warnings. 5 cents in addition:

  • It make sense to make the same automatic replacement for cv::error and some other related identifiers to 4.x. Otherwise it generates merge hell.
  • I would prefer do not touch SANITY_CHECK macros in tests.

@mshabunin
Copy link
Contributor Author

@asmorkalov , alternative to changes in perf tests is modifying opencv_extra: it uses full testcase name as key for sanity check data (https://github.com/opencv/opencv_extra/blob/798ea12f204aab96fe54a5a94c855e1238de0690/testdata/perf/core.xml#L45276). So we need to rename these cases in XML or add new entries with same contents. I thought we tend to remove sanity checks in performance tests and leave this task for accuracy tests.

I'll try to backport these changes to 4.x manually in a separate PR.

* removed apps
* removed traincascade tutorial
* removed imgproc_c.h mention from all files
* replaced old error constants
* replaced some more constants (NORM_, RNG::, PCA::, ...)
* replaced CV_ERROR usage with CV_Error
* imgproc/imgproc_c.h
* imgproc/types_c.h
@mshabunin mshabunin force-pushed the cleanup-imgproc-1 branch from 5294cb3 to 6b795fd Compare March 1, 2024 08:12
Copy link
Contributor

@asmorkalov asmorkalov left a comment

Choose a reason for hiding this comment

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

👍

@asmorkalov asmorkalov added category: core cleanup Code cleanup (e.g, drop legacy C-API, legacy unmaintained code) category: objdetect labels Mar 1, 2024
@asmorkalov asmorkalov added this to the 5.0 milestone Mar 1, 2024
asmorkalov added a commit to asmorkalov/opencv that referenced this pull request Mar 4, 2024
asmorkalov added a commit to asmorkalov/opencv that referenced this pull request Mar 5, 2024
@asmorkalov asmorkalov merged commit 8cbdd0c into opencv:5.x Mar 5, 2024
@asmorkalov asmorkalov self-assigned this Mar 5, 2024
asmorkalov added a commit that referenced this pull request Mar 5, 2024
@mshabunin mshabunin deleted the cleanup-imgproc-1 branch March 5, 2024 11:56
@asmorkalov asmorkalov mentioned this pull request Apr 1, 2024
klatism pushed a commit to klatism/opencv that referenced this pull request May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: core category: imgproc category: objdetect cleanup Code cleanup (e.g, drop legacy C-API, legacy unmaintained code)

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants