MCPcopy Create free account
hub / github.com/ajbrock/BigGAN-PyTorch / patch_replication_callback

Function patch_replication_callback

sync_batchnorm/replicate.py:70–94  ·  view source on GitHub ↗

Monkey-patch an existing `DataParallel` object. Add the replication callback. Useful when you have customized `DataParallel` implementation. Examples: > sync_bn = SynchronizedBatchNorm1d(10, eps=1e-5, affine=False) > sync_bn = DataParallel(sync_bn, device_ids=[0, 1])

(data_parallel)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

runFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected