MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / __init__

Method __init__

tensorflow/python/distribute/hvd_strategy.py:391–394  ·  view source on GitHub ↗
(self, *args, **kwargs)

Source from the content-addressed store, hash-verified

389 '''
390 class HvdOptimizer(cls, optimizer.Optimizer):
391 def __init__(self, *args, **kwargs):
392 kwargs["learning_rate"] = kwargs.get("learning_rate", 0.001) *\
393 HvdContext.get().world_size
394 super(HvdOptimizer, self).__init__(*args, **kwargs)
395
396 def compute_gradients(self, loss, **kwargs):
397 loss = hvd.allreduce(loss, op=hvd.Sum)

Callers

nothing calls this directly

Calls 2

getMethod · 0.45
__init__Method · 0.45

Tested by

no test coverage detected