mirror of
https://github.com/opencv/opencv.git
synced 2025-01-18 22:44:02 +08:00
temporarily disabled java bindings for ml; hopefully fixed warnings etc.
This commit is contained in:
parent
2520e335d1
commit
8e9d1d9fe6
@ -6,7 +6,7 @@ if(IOS OR NOT PYTHON_EXECUTABLE OR NOT ANT_EXECUTABLE OR NOT (JNI_FOUND OR (ANDR
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(the_description "The java bindings")
|
set(the_description "The java bindings")
|
||||||
ocv_add_module(java BINDINGS opencv_core opencv_imgproc OPTIONAL opencv_objdetect opencv_features2d opencv_video opencv_imgcodecs opencv_videoio opencv_ml opencv_calib3d opencv_photo opencv_nonfree opencv_contrib)
|
ocv_add_module(java BINDINGS opencv_core opencv_imgproc OPTIONAL opencv_objdetect opencv_features2d opencv_video opencv_imgcodecs opencv_videoio opencv_calib3d opencv_photo opencv_nonfree opencv_contrib)
|
||||||
ocv_module_include_directories("${CMAKE_CURRENT_SOURCE_DIR}/generator/src/cpp")
|
ocv_module_include_directories("${CMAKE_CURRENT_SOURCE_DIR}/generator/src/cpp")
|
||||||
|
|
||||||
if(NOT ANDROID)
|
if(NOT ANDROID)
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
from __future__ import print_function
|
from __future__ import print_function
|
||||||
import os, sys, re, string, fnmatch
|
import os, sys, re, string, fnmatch
|
||||||
allmodules = ["core", "flann", "imgproc", "ml", "imgcodecs", "videoio", "highgui", "video", "features2d", "calib3d", "objdetect", "legacy", "contrib", "cuda", "androidcamera", "java", "python", "stitching", "ts", "photo", "nonfree", "videostab", "softcascade", "superres"]
|
allmodules = ["core", "flann", "imgproc", "imgcodecs", "videoio", "highgui", "video", "features2d", "calib3d", "objdetect", "legacy", "contrib", "cuda", "androidcamera", "java", "python", "stitching", "ts", "photo", "nonfree", "videostab", "softcascade", "superres"]
|
||||||
verbose = False
|
verbose = False
|
||||||
show_warnings = True
|
show_warnings = True
|
||||||
show_errors = True
|
show_errors = True
|
||||||
|
@ -14,10 +14,6 @@
|
|||||||
# include "opencv2/video.hpp"
|
# include "opencv2/video.hpp"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_OPENCV_ML
|
|
||||||
# include "opencv2/ml.hpp"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef HAVE_OPENCV_CONTRIB
|
#ifdef HAVE_OPENCV_CONTRIB
|
||||||
# include "opencv2/contrib.hpp"
|
# include "opencv2/contrib.hpp"
|
||||||
#endif
|
#endif
|
||||||
@ -41,10 +37,7 @@ JNI_OnLoad(JavaVM* vm, void* )
|
|||||||
#ifdef HAVE_OPENCV_VIDEO
|
#ifdef HAVE_OPENCV_VIDEO
|
||||||
init &= cv::initModule_video();
|
init &= cv::initModule_video();
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_OPENCV_ML
|
#ifdef HAVE_OPENCV_CONTRIB
|
||||||
init &= cv::initModule_ml();
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_OPENCV_CONTRIB
|
|
||||||
init &= cv::initModule_contrib();
|
init &= cv::initModule_contrib();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -170,7 +170,7 @@ TEST(DISABLED_ML_ERTrees, save_load) { CV_SLMLTest test( CV_ERTREES ); test.safe
|
|||||||
TEST(DISABLED_ML_SVM, linear_save_load)
|
TEST(DISABLED_ML_SVM, linear_save_load)
|
||||||
{
|
{
|
||||||
Ptr<cv::ml::SVM> svm1, svm2, svm3;
|
Ptr<cv::ml::SVM> svm1, svm2, svm3;
|
||||||
|
|
||||||
svm1 = StatModel::load<SVM>("SVM45_X_38-1.xml");
|
svm1 = StatModel::load<SVM>("SVM45_X_38-1.xml");
|
||||||
svm2 = StatModel::load<SVM>("SVM45_X_38-2.xml");
|
svm2 = StatModel::load<SVM>("SVM45_X_38-2.xml");
|
||||||
string tname = tempfile("a.xml");
|
string tname = tempfile("a.xml");
|
||||||
|
@ -376,6 +376,12 @@ static bool pyopencv_to(PyObject* o, Mat& m, const ArgInfo info)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template<>
|
||||||
|
bool pyopencv_to(PyObject* o, Mat& m, const char* name)
|
||||||
|
{
|
||||||
|
return pyopencv_to(o, m, ArgInfo(name, 0));
|
||||||
|
}
|
||||||
|
|
||||||
template<>
|
template<>
|
||||||
PyObject* pyopencv_from(const Mat& m)
|
PyObject* pyopencv_from(const Mat& m)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user