MCPcopy Create free account
hub / github.com/RingBDStack/GDAP / any_requires_grad

Function any_requires_grad

seq2seq/utils.py:573–574  ·  view source on GitHub ↗
(model: nn.Module)

Source from the content-addressed store, hash-verified

571
572
573def any_requires_grad(model: nn.Module) -> bool:
574 return any(grad_status(model))
575
576
577def assert_all_frozen(model):

Callers

nothing calls this directly

Calls 1

grad_statusFunction · 0.85

Tested by

no test coverage detected