fix: remove redundant rotary embedding cache recomputation in MiniCPM (#8022)

This commit is contained in:
Xinyuan Tong
2025-07-15 00:12:45 -07:00
committed by GitHub
parent 6e923dbd30
commit 9120e83d03

View File

@@ -138,8 +138,6 @@ class MiniCPMAttention(nn.Module):
base=rope_theta,
rope_scaling=rope_scaling,
)
# set rope as fp32 instead of bf16
self.rotary_emb.cos_sin_cache = self.rotary_emb._compute_cos_sin_cache()
self.attn = RadixAttention(
self.num_heads,
self.head_dim,