fix import distributed nn
This commit is contained in:
parent
5283c1bc06
commit
1e0c408ffb
4 changed files with 6 additions and 4 deletions
|
|
@ -63,8 +63,8 @@ void allreduce_mean_tensor(Tensor* tensor) {
|
|||
// Perform NCCL AllReduce operation to calculate the mean of all tensors across all processes
|
||||
NCCL_CHECK(ncclAllReduce(tensor->data, tensor->data, tensor->size, ncclFloat, ncclSum, nccl_comm, stream));
|
||||
|
||||
tensor_div_scalar(tensor, tensor->data);
|
||||
|
||||
tensor_div_scalar_cuda(tensor, world_size, tensor->data);
|
||||
|
||||
cudaStreamSynchronize(stream);
|
||||
cudaStreamDestroy(stream);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue