We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9661896 commit 2a79471Copy full SHA for 2a79471
src/transformers/integrations/bitnet.py
@@ -362,8 +362,8 @@ def _replace_with_bitnet_linear(
362
bias=module.bias is not None,
363
device=module.weight.device,
364
dtype=module.weight.dtype,
365
- use_rms_norm=quantization_config.use_rms_norm,
366
- rms_norm_eps=quantization_config.rms_norm_eps,
+ use_rms_norm=quantization_config.use_rms_norm if quantization_config else False,
+ rms_norm_eps=quantization_config.rms_norm_eps if quantization_config else 1e-6,
367
)
368
model._modules[name].requires_grad_(False)
369
has_been_replaced = True
0 commit comments