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
e31244cf
Unverified
Commit
e31244cf
authored
Feb 06, 2021
by
James Lamb
Committed by
GitHub
Feb 07, 2021
Browse files
fix typos in log messages (#3914)
parent
a60d45c5
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
10 deletions
+10
-10
src/io/dataset.cpp
src/io/dataset.cpp
+1
-1
src/network/network.cpp
src/network/network.cpp
+5
-5
src/treelearner/cuda_tree_learner.cpp
src/treelearner/cuda_tree_learner.cpp
+2
-2
src/treelearner/gpu_tree_learner.cpp
src/treelearner/gpu_tree_learner.cpp
+2
-2
No files found.
src/io/dataset.cpp
View file @
e31244cf
...
@@ -1232,7 +1232,7 @@ void Dataset::ConstructHistogramsInner(
...
@@ -1232,7 +1232,7 @@ void Dataset::ConstructHistogramsInner(
}
}
}
}
// explicitly initilize template methods, for cross module call
// explicitly initi
a
lize template methods, for cross module call
template
void
Dataset
::
ConstructHistogramsInner
<
true
,
true
>(
template
void
Dataset
::
ConstructHistogramsInner
<
true
,
true
>(
const
std
::
vector
<
int8_t
>&
is_feature_used
,
const
data_size_t
*
data_indices
,
const
std
::
vector
<
int8_t
>&
is_feature_used
,
const
data_size_t
*
data_indices
,
data_size_t
num_data
,
const
score_t
*
gradients
,
const
score_t
*
hessians
,
data_size_t
num_data
,
const
score_t
*
gradients
,
const
score_t
*
hessians
,
...
...
src/network/network.cpp
View file @
e31244cf
...
@@ -67,7 +67,7 @@ void Network::Dispose() {
...
@@ -67,7 +67,7 @@ void Network::Dispose() {
void
Network
::
Allreduce
(
char
*
input
,
comm_size_t
input_size
,
int
type_size
,
char
*
output
,
const
ReduceFunction
&
reducer
)
{
void
Network
::
Allreduce
(
char
*
input
,
comm_size_t
input_size
,
int
type_size
,
char
*
output
,
const
ReduceFunction
&
reducer
)
{
if
(
num_machines_
<=
1
)
{
if
(
num_machines_
<=
1
)
{
Log
::
Fatal
(
"Please initilize the network interface first"
);
Log
::
Fatal
(
"Please initi
a
lize the network interface first"
);
}
}
comm_size_t
count
=
input_size
/
type_size
;
comm_size_t
count
=
input_size
/
type_size
;
// if small package or small count , do it by all gather.(reduce the communication times.)
// if small package or small count , do it by all gather.(reduce the communication times.)
...
@@ -94,7 +94,7 @@ void Network::Allreduce(char* input, comm_size_t input_size, int type_size, char
...
@@ -94,7 +94,7 @@ void Network::Allreduce(char* input, comm_size_t input_size, int type_size, char
void
Network
::
AllreduceByAllGather
(
char
*
input
,
comm_size_t
input_size
,
int
type_size
,
char
*
output
,
const
ReduceFunction
&
reducer
)
{
void
Network
::
AllreduceByAllGather
(
char
*
input
,
comm_size_t
input_size
,
int
type_size
,
char
*
output
,
const
ReduceFunction
&
reducer
)
{
if
(
num_machines_
<=
1
)
{
if
(
num_machines_
<=
1
)
{
Log
::
Fatal
(
"Please initilize the network interface first"
);
Log
::
Fatal
(
"Please initi
a
lize the network interface first"
);
}
}
// assign blocks
// assign blocks
comm_size_t
all_size
=
input_size
*
num_machines_
;
comm_size_t
all_size
=
input_size
*
num_machines_
;
...
@@ -120,7 +120,7 @@ void Network::AllreduceByAllGather(char* input, comm_size_t input_size, int type
...
@@ -120,7 +120,7 @@ void Network::AllreduceByAllGather(char* input, comm_size_t input_size, int type
void
Network
::
Allgather
(
char
*
input
,
comm_size_t
send_size
,
char
*
output
)
{
void
Network
::
Allgather
(
char
*
input
,
comm_size_t
send_size
,
char
*
output
)
{
if
(
num_machines_
<=
1
)
{
if
(
num_machines_
<=
1
)
{
Log
::
Fatal
(
"Please initilize the network interface first"
);
Log
::
Fatal
(
"Please initi
a
lize the network interface first"
);
return
;
return
;
}
}
// assign blocks
// assign blocks
...
@@ -136,7 +136,7 @@ void Network::Allgather(char* input, comm_size_t send_size, char* output) {
...
@@ -136,7 +136,7 @@ void Network::Allgather(char* input, comm_size_t send_size, char* output) {
void
Network
::
Allgather
(
char
*
input
,
const
comm_size_t
*
block_start
,
const
comm_size_t
*
block_len
,
char
*
output
,
comm_size_t
all_size
)
{
void
Network
::
Allgather
(
char
*
input
,
const
comm_size_t
*
block_start
,
const
comm_size_t
*
block_len
,
char
*
output
,
comm_size_t
all_size
)
{
if
(
num_machines_
<=
1
)
{
if
(
num_machines_
<=
1
)
{
Log
::
Fatal
(
"Please initilize the network interface first"
);
Log
::
Fatal
(
"Please initi
a
lize the network interface first"
);
}
}
if
(
allgather_ext_fun_
!=
nullptr
)
{
if
(
allgather_ext_fun_
!=
nullptr
)
{
return
allgather_ext_fun_
(
input
,
block_len
[
rank_
],
block_start
,
block_len
,
num_machines_
,
output
,
all_size
);
return
allgather_ext_fun_
(
input
,
block_len
[
rank_
],
block_start
,
block_len
,
num_machines_
,
output
,
all_size
);
...
@@ -233,7 +233,7 @@ void Network::ReduceScatter(char* input, comm_size_t input_size, int type_size,
...
@@ -233,7 +233,7 @@ void Network::ReduceScatter(char* input, comm_size_t input_size, int type_size,
const
comm_size_t
*
block_start
,
const
comm_size_t
*
block_len
,
char
*
output
,
const
comm_size_t
*
block_start
,
const
comm_size_t
*
block_len
,
char
*
output
,
comm_size_t
output_size
,
const
ReduceFunction
&
reducer
)
{
comm_size_t
output_size
,
const
ReduceFunction
&
reducer
)
{
if
(
num_machines_
<=
1
)
{
if
(
num_machines_
<=
1
)
{
Log
::
Fatal
(
"Please initilize the network interface first"
);
Log
::
Fatal
(
"Please initi
a
lize the network interface first"
);
}
}
if
(
reduce_scatter_ext_fun_
!=
nullptr
)
{
if
(
reduce_scatter_ext_fun_
!=
nullptr
)
{
return
reduce_scatter_ext_fun_
(
input
,
input_size
,
type_size
,
block_start
,
block_len
,
num_machines_
,
output
,
output_size
,
reducer
);
return
reduce_scatter_ext_fun_
(
input
,
input_size
,
type_size
,
block_start
,
block_len
,
num_machines_
,
output
,
output_size
,
reducer
);
...
...
src/treelearner/cuda_tree_learner.cpp
View file @
e31244cf
...
@@ -470,10 +470,10 @@ void CUDATreeLearner::InitGPU(int num_gpu) {
...
@@ -470,10 +470,10 @@ void CUDATreeLearner::InitGPU(int num_gpu) {
Log
::
Fatal
(
"bin size %d cannot run on GPU"
,
max_num_bin_
);
Log
::
Fatal
(
"bin size %d cannot run on GPU"
,
max_num_bin_
);
}
}
if
(
max_num_bin_
==
65
)
{
if
(
max_num_bin_
==
65
)
{
Log
::
Warning
(
"Setting max_bin to 63 is sugg
u
ested for best performance"
);
Log
::
Warning
(
"Setting max_bin to 63 is suggested for best performance"
);
}
}
if
(
max_num_bin_
==
17
)
{
if
(
max_num_bin_
==
17
)
{
Log
::
Warning
(
"Setting max_bin to 15 is sugg
u
ested for best performance"
);
Log
::
Warning
(
"Setting max_bin to 15 is suggested for best performance"
);
}
}
// get num_dense_feature_groups_
// get num_dense_feature_groups_
...
...
src/treelearner/gpu_tree_learner.cpp
View file @
e31244cf
...
@@ -720,10 +720,10 @@ void GPUTreeLearner::InitGPU(int platform_id, int device_id) {
...
@@ -720,10 +720,10 @@ void GPUTreeLearner::InitGPU(int platform_id, int device_id) {
Log
::
Fatal
(
"bin size %d cannot run on GPU"
,
max_num_bin_
);
Log
::
Fatal
(
"bin size %d cannot run on GPU"
,
max_num_bin_
);
}
}
if
(
max_num_bin_
==
65
)
{
if
(
max_num_bin_
==
65
)
{
Log
::
Warning
(
"Setting max_bin to 63 is sugg
u
ested for best performance"
);
Log
::
Warning
(
"Setting max_bin to 63 is suggested for best performance"
);
}
}
if
(
max_num_bin_
==
17
)
{
if
(
max_num_bin_
==
17
)
{
Log
::
Warning
(
"Setting max_bin to 15 is sugg
u
ested for best performance"
);
Log
::
Warning
(
"Setting max_bin to 15 is suggested for best performance"
);
}
}
ctx_
=
boost
::
compute
::
context
(
dev_
);
ctx_
=
boost
::
compute
::
context
(
dev_
);
queue_
=
boost
::
compute
::
command_queue
(
ctx_
,
dev_
);
queue_
=
boost
::
compute
::
command_queue
(
ctx_
,
dev_
);
...
...
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