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
88110631
Unverified
Commit
88110631
authored
Mar 15, 2023
by
Aleksandar Bojarov
Committed by
GitHub
Mar 15, 2023
Browse files
Fix DEBUG-mode GPU builds (#5778)
Fix for DEBUG mode This commit fixes issue #5777
parent
814a2f1c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
src/treelearner/cuda/cuda_single_gpu_tree_learner.cpp
src/treelearner/cuda/cuda_single_gpu_tree_learner.cpp
+2
-2
src/treelearner/cuda/cuda_single_gpu_tree_learner.hpp
src/treelearner/cuda/cuda_single_gpu_tree_learner.hpp
+1
-1
No files found.
src/treelearner/cuda/cuda_single_gpu_tree_learner.cpp
View file @
88110631
...
@@ -94,8 +94,8 @@ void CUDASingleGPUTreeLearner::BeforeTrain() {
...
@@ -94,8 +94,8 @@ void CUDASingleGPUTreeLearner::BeforeTrain() {
}
}
#ifdef DEBUG
#ifdef DEBUG
CopyFromCUDADeviceToHost
<
score_t
>
(
host_gradients
.
data
(),
gradients_
,
static_cast
<
size_t
>
(
num_data_
),
__FILE__
,
__LINE__
);
CopyFromCUDADeviceToHost
<
score_t
>
(
host_gradients
_
.
data
(),
gradients_
,
static_cast
<
size_t
>
(
num_data_
),
__FILE__
,
__LINE__
);
CopyFromCUDADeviceToHost
<
score_t
>
(
host_hessians
.
data
(),
hessians_
,
static_cast
<
size_t
>
(
num_data_
),
__FILE__
,
__LINE__
);
CopyFromCUDADeviceToHost
<
score_t
>
(
host_hessians
_
.
data
(),
hessians_
,
static_cast
<
size_t
>
(
num_data_
),
__FILE__
,
__LINE__
);
#endif // DEBUG
#endif // DEBUG
const
data_size_t
*
leaf_splits_init_indices
=
const
data_size_t
*
leaf_splits_init_indices
=
...
...
src/treelearner/cuda/cuda_single_gpu_tree_learner.hpp
View file @
88110631
...
@@ -68,7 +68,7 @@ class CUDASingleGPUTreeLearner: public SerialTreeLearner {
...
@@ -68,7 +68,7 @@ class CUDASingleGPUTreeLearner: public SerialTreeLearner {
void
SelectFeatureByNode
(
const
Tree
*
tree
);
void
SelectFeatureByNode
(
const
Tree
*
tree
);
#ifdef DE
U
BG
#ifdef DEB
U
G
void
CheckSplitValid
(
void
CheckSplitValid
(
const
int
left_leaf
,
const
int
right_leaf
,
const
int
left_leaf
,
const
int
right_leaf
,
const
double
sum_left_gradients
,
const
double
sum_right_gradients
);
const
double
sum_left_gradients
,
const
double
sum_right_gradients
);
...
...
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