MCPcopy Create free account
hub / github.com/OpenGVLab/EfficientQAT / weight_parameters

Function weight_parameters

quantize/utils.py:32–37  ·  view source on GitHub ↗
(model)

Source from the content-addressed store, hash-verified

30 return iter(params)
31
32def weight_parameters(model):
33 params = []
34 for n, m in model.named_parameters():
35 if n.find('weight') > -1 and not (n.find('scale') > -1 or n.find('zero_point') > -1):
36 params.append(m)
37 return iter(params)
38
39def set_quant_parameters(model, requires_grad):
40 params = []

Callers 1

block_apFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected