Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dlib
Commits
461abe65
Commit
461abe65
authored
May 04, 2014
by
Davis King
Browse files
Added missing assert
parent
9980013c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
dlib/svm/svm_c_linear_trainer.h
dlib/svm/svm_c_linear_trainer.h
+11
-0
No files found.
dlib/svm/svm_c_linear_trainer.h
View file @
461abe65
...
...
@@ -628,6 +628,17 @@ namespace dlib
if
(
has_prior
())
{
if
(
is_matrix
<
sample_type
>::
value
)
{
// make sure requires clause is not broken
DLIB_CASSERT
(
num_dims
+
1
==
(
unsigned
long
)
prior
.
size
(),
"
\t
decision_function svm_c_linear_trainer::train(x,y)"
<<
"
\n\t
The dimension of the training vectors must match the dimension of
\n
"
<<
"
\n\t
those used to create the prior."
<<
"
\n\t
num_dims: "
<<
num_dims
<<
"
\n\t
prior.size(): "
<<
prior
.
size
()
);
}
svm_objective
=
solver
(
make_oca_problem_c_svm
<
w_type
>
(
Cpos
,
Cneg
,
x
,
y
,
verbose
,
eps
,
max_iterations
),
w
,
...
...
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