Commit 26d89be7 authored by fengzch's avatar fengzch
Browse files

fix: 取消对sparse attention的依赖

parent 781a9ec8
flash_c_api 放在third_party目录下
编译指令:
source /opt/dtk/env.sh
source /usr/local/bin/fastpt -T
......
......@@ -100,7 +100,7 @@ if __name__ == "__main__":
"third_party/json/include",
"third_party/mio/include",
"third_party/spdlog/include",
"third_party/Block-Sparse-Attention/csrc/block_sparse_attn",
# "third_party/Block-Sparse-Attention/csrc/block_sparse_attn",
"third_party/flash_c_api/include",
]
......
......@@ -278,6 +278,7 @@ Tensor Attention::forward(Tensor qkv, Tensor pool_qkv, float sparsityRatio) {
// -1,
// -1)
// .front();
Tensor raw_attn_output = Tensor::ones({batch_size * num_tokens, num_heads, dim_head}, Tensor::FP16, Device::cuda());
std::cout << "mha_fwd_block not support !!!" << std::endl;
debug("raw_attn_output", raw_attn_output);
......
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