MCPcopy Create free account
hub / github.com/BICLab/SpikingBrain-7B / __init__

Method __init__

W8ASpike/quant_linear.py:22–27  ·  view source on GitHub ↗
(self, in_features: int, out_features: int, bias: bool = True, device=None, dtype=None, w_group_size=128, dynamic_sfr=3.0)

Source from the content-addressed store, hash-verified

20
21class QuantLinear(nn.Linear):
22 def __init__(self, in_features: int, out_features: int, bias: bool = True, device=None, dtype=None, w_group_size=128, dynamic_sfr=3.0):
23 super().__init__(in_features, out_features, bias, device=device, dtype=dtype)
24
25 self.k = dynamic_sfr
26 self.w_group_size = w_group_size
27 self.weight_quantizer = Quantizer(in_features, out_features, w_group_size)
28
29 def forward(self, x):
30 # BLD

Callers

nothing calls this directly

Calls 2

QuantizerClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected