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
92351659
Commit
92351659
authored
Nov 24, 2016
by
Guolin Ke
Committed by
GitHub
Nov 24, 2016
Browse files
quick fix for bug of negative index
parent
19e085c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/io/sparse_bin.hpp
src/io/sparse_bin.hpp
+1
-1
No files found.
src/io/sparse_bin.hpp
View file @
92351659
...
...
@@ -279,7 +279,7 @@ inline VAL_T SparseBinIterator<VAL_T>::InnerGet(data_size_t idx) {
while
(
cur_pos_
<
idx
&&
i_delta_
<
bin_data_
->
num_vals_
)
{
bin_data_
->
NextNonzero
(
&
i_delta_
,
&
cur_pos_
);
}
if
(
cur_pos_
==
idx
&&
i_delta_
<
bin_data_
->
num_vals_
)
{
if
(
cur_pos_
==
idx
&&
i_delta_
<
bin_data_
->
num_vals_
&&
i_delta_
>=
0
)
{
return
bin_data_
->
vals_
[
i_delta_
];
}
else
{
return
0
;
...
...
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