Unverified Commit 9120e83d authored by Xinyuan Tong's avatar Xinyuan Tong Committed by GitHub
Browse files

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

parent 6e923dbd
...@@ -138,8 +138,6 @@ class MiniCPMAttention(nn.Module): ...@@ -138,8 +138,6 @@ class MiniCPMAttention(nn.Module):
base=rope_theta, base=rope_theta,
rope_scaling=rope_scaling, 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.attn = RadixAttention(
self.num_heads, self.num_heads,
self.head_dim, self.head_dim,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment