From 002641814e2923126cb57dd184713cac059d52c6 Mon Sep 17 00:00:00 2001 From: yuanlehome Date: Tue, 29 Oct 2024 15:17:50 +0800 Subject: [PATCH] fix bug --- .../experimental/transformers/fused_transformer_layers.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/paddlenlp/experimental/transformers/fused_transformer_layers.py b/paddlenlp/experimental/transformers/fused_transformer_layers.py index 9f213a08cd04..7c1dadc43ce6 100644 --- a/paddlenlp/experimental/transformers/fused_transformer_layers.py +++ b/paddlenlp/experimental/transformers/fused_transformer_layers.py @@ -2236,7 +2236,7 @@ def compute_attn( quant_round_type=self.config.quant_round_type, quant_max_bound=self.config.quant_max_bound, quant_min_bound=self.config.quant_min_bound, - rope_theta=self.rope_theta, + rope_theta=self.config.rope_theta, )[0] else: k_quant_scales = kwargs.get("k_quant_scales", None) @@ -2278,7 +2278,7 @@ def compute_attn( quant_round_type=self.config.quant_round_type, quant_max_bound=self.config.quant_max_bound, quant_min_bound=self.config.quant_min_bound, - rope_theta=self.rope_theta, + rope_theta=self.config.rope_theta, )[0] out_linear_out = self.compute_out_linear(fmha_out, i) @@ -2424,7 +2424,7 @@ def compute_attn( quant_min_bound=self.quant_min_bound, out_scale=self.act_scales["out_linear_in_scale"][i], compute_dtype=self._fuse_kernel_compute_dtype, - rope_theta=self.rope_theta, + rope_theta=self.config.rope_theta, )[0] out_linear_out = self.compute_out_linear(fmha_out, i) @@ -2937,7 +2937,7 @@ def compute_attn( quant_max_bound=self.config.quant_max_bound, quant_min_bound=self.config.quant_min_bound, out_scale=self.act_scales.scale["out_linear_in_scale"][i], - rope_theta=self.rope_theta, + rope_theta=self.config.rope_theta, )[0] out_linear_out = self.compute_out_linear(fmha_out, i)