Skip to content

Commit a692fea

Browse files
ZiyueHuangjasperzhong
authored andcommitted
hotfix: fix distributed initialization bytedance#285
1 parent 6673b7d commit a692fea

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

byteps/mxnet/__init__.py

+1-4
Original file line numberDiff line numberDiff line change
@@ -326,12 +326,9 @@ def _init_params(self):
326326
param_arrays = param._check_and_get(param._data, list)
327327
idx = self._param2idx[param.name]
328328

329-
if rank() != self.root_rank:
330-
param_arrays[0].__imul__(0)
331-
332329
compressed, ctx = self._intra_compressors[param.name].compress(
333330
param_arrays[0])
334-
byteps_push_pull(compressed, version=0, priority=0,
331+
byteps_push_pull(param_arrays[0], version=0, priority=0,
335332
name="parameter_" + str(idx), is_average=False)
336333
param_arrays[0][:] = self._intra_compressors[param.name].decompress(
337334
compressed, ctx, x=param._data[0])

0 commit comments

Comments
 (0)