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
0f3d90e7
Unverified
Commit
0f3d90e7
authored
May 04, 2018
by
Guolin Ke
Committed by
GitHub
May 04, 2018
Browse files
increase the threshold of using predict_by_map
parent
ed3d774c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/application/predictor.hpp
src/application/predictor.hpp
+2
-2
No files found.
src/application/predictor.hpp
View file @
0f3d90e7
...
...
@@ -60,8 +60,8 @@ public:
num_pred_one_row_
=
boosting_
->
NumPredictOneRow
(
num_iteration
,
is_predict_leaf_index
,
is_predict_contrib
);
num_feature_
=
boosting_
->
MaxFeatureIdx
()
+
1
;
predict_buf_
=
std
::
vector
<
std
::
vector
<
double
>>
(
num_threads_
,
std
::
vector
<
double
>
(
num_feature_
,
0.0
f
));
const
int
kFeatureThreshold
=
2
0000
;
const
size_t
KSparseThreshold
=
static_cast
<
size_t
>
(
0.0
2
*
num_feature_
);
const
int
kFeatureThreshold
=
10
0000
;
const
size_t
KSparseThreshold
=
static_cast
<
size_t
>
(
0.0
1
*
num_feature_
);
if
(
is_predict_leaf_index
)
{
predict_fun_
=
[
this
,
kFeatureThreshold
,
KSparseThreshold
](
const
std
::
vector
<
std
::
pair
<
int
,
double
>>&
features
,
double
*
output
)
{
int
tid
=
omp_get_thread_num
();
...
...
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