Commit 4cf0e5d7 authored by gy741's avatar gy741 Committed by Guolin Ke
Browse files

Remove Duplicate code in Network::Allgather() (#1733)

parent f66716ce
...@@ -117,8 +117,8 @@ void Network::AllreduceByAllGather(char* input, comm_size_t input_size, int type ...@@ -117,8 +117,8 @@ 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 initilize the network interface first");
return;
} }
if (num_machines_ <= 1) { return; }
// assign blocks // assign blocks
block_start_[0] = 0; block_start_[0] = 0;
block_len_[0] = send_size; block_len_[0] = send_size;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment