opencv/opencv

Move ML module to opencv_contrib

vpisarev opened this issue · 7 comments

Describe the feature and motivation

After ~25 years of developing OpenCV and ~20 years of opencv_ml module history we found that it's time to move ML outside of the main repository. Here are the major reasons:

  • ML module is not used in other parts of OpenCV, it's not used in any samples or tutorials, except for samples or tutorials for ML itself. Very few, if any, people from OpenCV community actually use it.
  • Traditional ML has been completely replaced with Deep Learning in Computer Vision.
  • Traditional ML, including decision trees, boosting (especially gradient boosting), support vector machines etc. is still actively used by scientific community, but there are high-quality packages that implement state-of-art approaches, most notable of which is scikit-learn. We don't see any strong reason and don't have any resources to compete with such packages.

So, we are going to move ML module to opencv_contrib together with tests, samples, docs/tutorials.

Additional context

No response

Consider that there are still people that want such stuff reachable from C++, so scikit-learn is a great substitute for many users, but not all. I see no issues with the module being moved to contrib.

kmeans and PCA should be moved out of the core module first (higher priority than touching of "standalone" ML module)

@opencv-alalek, moved where? kmeans is still quite actively used. PCA maybe less so, but it's quite fundamental thing that is still used, even with deep nets (it's the 'cheapest' auto-encoder)

ML module is a best candidate as target, but it's suggested to be removed.