MCPcopy Create free account
hub / github.com/QWTforGithub/T2LDM / _kernel_valid

Function _kernel_valid

timm/models/layers/selective_kernel.py:14–18  ·  view source on GitHub ↗
(k)

Source from the content-addressed store, hash-verified

12
13
14def _kernel_valid(k):
15 if isinstance(k, (list, tuple)):
16 for ki in k:
17 return _kernel_valid(ki)
18 assert k >= 3 and k % 2
19
20
21class SelectiveKernelAttn(nn.Module):

Callers 1

__init__Method · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected