MCPcopy Create free account
hub / github.com/OpenBMB/VisRAG / convert_splitbn_model

Function convert_splitbn_model

timm_modified/timm/layers/split_batchnorm.py:41–75  ·  view source on GitHub ↗

Recursively traverse module and its children to replace all instances of ``torch.nn.modules.batchnorm._BatchNorm`` with `SplitBatchnorm2d`. Args: module (torch.nn.Module): input module num_splits: number of separate batchnorm layers to split input across Example::

(module, num_splits=2)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

mainFunction · 0.90

Calls 1

SplitBatchNorm2dClass · 0.85

Tested by

no test coverage detected