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
1e8bc435
Commit
1e8bc435
authored
Aug 10, 2011
by
Davis King
Browse files
Relaxed test slightly to avoid false alarms.
parent
3f477c1f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
dlib/test/svm_c_linear_dcd.cpp
dlib/test/svm_c_linear_dcd.cpp
+3
-3
No files found.
dlib/test/svm_c_linear_dcd.cpp
View file @
1e8bc435
...
@@ -160,9 +160,9 @@ namespace
...
@@ -160,9 +160,9 @@ namespace
df3
=
linear_trainer
.
train
(
samples_explict_bias
,
labels
);
df3
=
linear_trainer
.
train
(
samples_explict_bias
,
labels
);
DLIB_TEST
(
std
::
abs
(
df2
.
basis_vectors
(
0
)(
9
))
<
1e-7
);
DLIB_TEST
(
std
::
abs
(
df2
.
basis_vectors
(
0
)(
9
))
<
1e-7
);
DLIB_TEST_MSG
(
max
(
abs
(
colm
(
df
.
basis_vectors
(
0
),
0
,
9
)
-
colm
(
df2
.
basis_vectors
(
0
),
0
,
9
)))
<
1e-
7
,
max
(
abs
(
colm
(
df
.
basis_vectors
(
0
),
0
,
9
)
-
colm
(
df2
.
basis_vectors
(
0
),
0
,
9
))));
DLIB_TEST_MSG
(
max
(
abs
(
colm
(
df
.
basis_vectors
(
0
),
0
,
9
)
-
colm
(
df2
.
basis_vectors
(
0
),
0
,
9
)))
<
1e-
6
,
max
(
abs
(
colm
(
df
.
basis_vectors
(
0
),
0
,
9
)
-
colm
(
df2
.
basis_vectors
(
0
),
0
,
9
))));
DLIB_TEST
(
std
::
abs
(
df
.
basis_vectors
(
0
)(
9
)
-
df2
.
b
)
<
1e-7
);
DLIB_TEST
(
std
::
abs
(
df
.
basis_vectors
(
0
)(
9
)
-
df2
.
b
)
<
1e-7
);
DLIB_TEST
(
max
(
abs
(
df
.
basis_vectors
(
0
)
-
df3
.
basis_vectors
(
0
)))
<
1e-
7
);
DLIB_TEST
(
max
(
abs
(
df
.
basis_vectors
(
0
)
-
df3
.
basis_vectors
(
0
)))
<
1e-
6
);
DLIB_TEST
(
std
::
abs
(
df
.
b
-
df3
.
b
)
<
1e-7
);
DLIB_TEST
(
std
::
abs
(
df
.
b
-
df3
.
b
)
<
1e-7
);
}
}
}
}
...
@@ -184,7 +184,7 @@ namespace
...
@@ -184,7 +184,7 @@ namespace
svm_c_linear_dcd_trainer
<
kernel_type
>::
optimizer_state
state
;
svm_c_linear_dcd_trainer
<
kernel_type
>::
optimizer_state
state
;
const
double
C
=
3
;
const
double
C
=
1
;
linear_trainer
.
set_epsilon
(
1e-10
);
linear_trainer
.
set_epsilon
(
1e-10
);
linear_trainer_cpa
.
set_epsilon
(
1e-10
);
linear_trainer_cpa
.
set_epsilon
(
1e-10
);
...
...
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