Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
d63a38e9
Commit
d63a38e9
authored
Oct 11, 2013
by
ilya-lavrenov
Committed by
Ilya Lavrenov
Oct 11, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
disable SVM when AMD BLAS is not available
parent
171e0e62
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
0 deletions
+10
-0
svm.cpp
modules/ocl/src/svm.cpp
+6
-0
test_ml.cpp
modules/ocl/test/test_ml.cpp
+4
-0
No files found.
modules/ocl/src/svm.cpp
View file @
d63a38e9
...
...
@@ -686,6 +686,9 @@ float CvSVM_OCL::predict(const CvMat* samples, CV_OUT CvMat* results) const
}
#else
// TODO fix it
CV_Error
(
CV_StsNotImplemented
,
"This part of code contains mistakes. Install AMD BLAS in order to get a correct result or use CPU version of SVM"
);
double
degree1
=
0.0
;
if
(
params
.
kernel_type
==
CvSVM
::
POLY
)
degree1
=
params
.
degree
;
...
...
@@ -810,6 +813,9 @@ bool CvSVMSolver_ocl::solve_generic( CvSVMSolutionInfo& si )
}
#else
// TODO fix it
CV_Error
(
CV_StsNotImplemented
,
"This part of code contains mistakes. Install AMD BLAS in order to get a correct result or use CPU version of SVM"
);
double
degree1
=
0.0
;
if
(
params
->
kernel_type
==
CvSVM
::
POLY
)
degree1
=
params
->
degree
;
...
...
modules/ocl/test/test_ml.cpp
View file @
d63a38e9
...
...
@@ -126,6 +126,8 @@ OCL_TEST_P(KNN, Accuracy)
INSTANTIATE_TEST_CASE_P
(
OCL_ML
,
KNN
,
Combine
(
Values
(
6
,
5
),
Values
(
Size
(
200
,
400
),
Size
(
300
,
600
)),
Values
(
4
,
3
),
Values
(
false
,
true
)));
#ifndef HAVE_CLAMDBLAS // TODO does not work non-blas version of SVM
////////////////////////////////SVM/////////////////////////////////////////////////
PARAM_TEST_CASE
(
SVM_OCL
,
int
,
int
,
int
)
...
...
@@ -306,4 +308,6 @@ INSTANTIATE_TEST_CASE_P(OCL_ML, SVM_OCL, testing::Combine(
Values
(
2
,
3
,
4
)
));
#endif // HAVE_CLAMDBLAS
#endif // HAVE_OPENCL
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment