Skip to content

Commit

Permalink
fix Fa bug for arm machine (#1245)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhenwenqi2024 committed May 20, 2024
1 parent aa755f6 commit 7397c7f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backends/npu/custom_op/fused_attention_npu.cc
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ std::vector<paddle::Tensor> npu_flash_attention(
"The value tensor dtype must be bfloat16 or float16 , but got ",
value_dtype);

const int32_t head_num = query_tensor_dims[2];
const int64_t head_num = query_tensor_dims[2];
const double scale = 1.0f / std::sqrt(query_tensor_dims[3]);

void* realShiftOptional = nullptr;
Expand Down

0 comments on commit 7397c7f

Please sign in to comment.