MCPcopy Create free account
hub / github.com/MotrixLab/FineMoGen / __init__

Method __init__

mogen/utils/dist_utils.py:46–49  ·  view source on GitHub ↗
(self, grad_clip=None, coalesce=True, bucket_size_mb=-1)

Source from the content-addressed store, hash-verified

44class DistOptimizerHook(OptimizerHook):
45
46 def __init__(self, grad_clip=None, coalesce=True, bucket_size_mb=-1):
47 self.grad_clip = grad_clip
48 self.coalesce = coalesce
49 self.bucket_size_mb = bucket_size_mb
50
51 def after_train_iter(self, runner):
52 runner.optimizer.zero_grad()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected