Fix in dropout lambda to avoid the compiling issue on some docker/compiler envs (#1350)

This commit is contained in:
Qianfeng
2024-06-20 11:36:42 +08:00
committed by GitHub
parent 8db331a511
commit e3f44659cf

View File

@@ -744,11 +744,11 @@ struct FmhaFwdKernel
}
}();
auto dropout = [&]() {
auto dropout = [&, i_nhead_ = i_nhead, i_batch_ = i_batch]() {
if constexpr(kHasDropout)
{
return BlockDropout{i_batch,
i_nhead,
return BlockDropout{i_batch_,
i_nhead_,
kargs.num_head_q,
kargs.drop_seed,
kargs.drop_offset,