MCPcopy Create free account
hub / github.com/THUDM/GLM / allreduce_hook

Method allreduce_hook

model/distributed.py:84–85  ·  view source on GitHub ↗
(*unused)

Source from the content-addressed store, hash-verified

82 self.hooks = []
83 for param in list(self.module.parameters()):
84 def allreduce_hook(*unused):
85 Variable._execution_engine.queue_callback(allreduce_params)
86 # handle = param.register_hook(allreduce_hook)
87 # self.hooks.append(allreduce_hook)
88 # self.hook_handles.append(handle)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected