Apply suggestion from @ngxson

This commit is contained in:
Xuan-Son Nguyen 2026-02-16 12:03:45 +01:00 committed by GitHub
parent 7f0fe9d1d5
commit 373da0e276
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -7284,7 +7284,7 @@ class Cohere2Model(TextModel):
self.gguf_writer.add_rope_scaling_type(gguf.RopeScalingType.NONE)
def modify_tensors(self, data_torch: Tensor, name: str, bid: int | None) -> Iterable[tuple[str, Tensor]]:
# Cohere2 runtime in llama.cpp expects no bias tensors;
# Cohere2 runtime in llama.cpp expects no bias tensors;
# the actual weight only contains 0-value tensors as bias, we can skip them
if name.endswith(".bias"):
if torch.any(data_torch != 0):