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
fd0cbe65
Commit
fd0cbe65
authored
Jan 23, 2017
by
Guolin Ke
Browse files
slight improve prediction speed
parent
4948dcc5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
5 deletions
+4
-5
include/LightGBM/tree.h
include/LightGBM/tree.h
+2
-2
src/io/tree.cpp
src/io/tree.cpp
+2
-3
No files found.
include/LightGBM/tree.h
View file @
fd0cbe65
...
@@ -138,8 +138,8 @@ public:
...
@@ -138,8 +138,8 @@ public:
}
}
}
}
static
std
::
vector
<
std
::
function
<
bool
(
unsigned
int
,
unsigned
int
)
>
>
inner_decision_funs
;
static
std
::
vector
<
bool
(
*
)(
unsigned
int
,
unsigned
int
)
>
inner_decision_funs
;
static
std
::
vector
<
std
::
function
<
bool
(
double
,
double
)
>
>
decision_funs
;
static
std
::
vector
<
bool
(
*
)(
double
,
double
)
>
decision_funs
;
private:
private:
/*!
/*!
...
...
src/io/tree.cpp
View file @
fd0cbe65
...
@@ -16,12 +16,11 @@
...
@@ -16,12 +16,11 @@
namespace
LightGBM
{
namespace
LightGBM
{
std
::
vector
<
std
::
function
<
bool
(
unsigned
int
,
unsigned
int
)
>
>
Tree
::
inner_decision_funs
=
std
::
vector
<
bool
(
*
)(
unsigned
int
,
unsigned
int
)
>
Tree
::
inner_decision_funs
=
{
Tree
::
NumericalDecision
<
unsigned
int
>
,
Tree
::
CategoricalDecision
<
unsigned
int
>
};
{
Tree
::
NumericalDecision
<
unsigned
int
>
,
Tree
::
CategoricalDecision
<
unsigned
int
>
};
std
::
vector
<
std
::
function
<
bool
(
double
,
double
)
>
>
Tree
::
decision_funs
=
std
::
vector
<
bool
(
*
)(
double
,
double
)
>
Tree
::
decision_funs
=
{
Tree
::
NumericalDecision
<
double
>
,
Tree
::
CategoricalDecision
<
double
>
};
{
Tree
::
NumericalDecision
<
double
>
,
Tree
::
CategoricalDecision
<
double
>
};
Tree
::
Tree
(
int
max_leaves
)
Tree
::
Tree
(
int
max_leaves
)
:
max_leaves_
(
max_leaves
)
{
:
max_leaves_
(
max_leaves
)
{
...
...
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