MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / expand_dhw

Function expand_dhw

imperative/python/megengine/functional/nn.py:124–129  ·  view source on GitHub ↗
(x)

Source from the content-addressed store, hash-verified

122
123
124def expand_dhw(x):
125 if isinstance(x, int):
126 return x, x, x
127 if isinstance(x, Sequence):
128 return int(x[0]), int(x[1]), int(x[2])
129 return int(x), int(x), int(x)
130
131
132def linear(

Callers 2

conv3dFunction · 0.85
conv_transpose3dFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected