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
tianlh
LightGBM-DCU
Commits
8aa15e88
Commit
8aa15e88
authored
Dec 23, 2016
by
Guolin Ke
Browse files
fix bug in multi_error
parent
db18367e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
src/metric/multiclass_metric.hpp
src/metric/multiclass_metric.hpp
+3
-3
No files found.
src/metric/multiclass_metric.hpp
View file @
8aa15e88
...
...
@@ -101,11 +101,11 @@ public:
inline
static
score_t
LossOnPoint
(
float
label
,
std
::
vector
<
double
>
score
)
{
size_t
k
=
static_cast
<
size_t
>
(
label
);
for
(
size_t
i
=
0
;
i
<
score
.
size
();
++
i
){
if
(
i
!=
k
&&
score
[
i
]
>
score
[
k
])
{
return
0
.0
f
;
if
(
i
!=
k
&&
score
[
i
]
>
=
score
[
k
])
{
return
1
.0
f
;
}
}
return
1
.0
f
;
return
0
.0
f
;
}
inline
static
const
char
*
Name
()
{
...
...
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