ziya2预训练的语料拼接是如何通过attention mask规避的
Opened this issue · 5 comments
linyubupa commented
zztMermory commented
同问+1
qibao77 commented
同问+1
ganzhiruyi commented
只需要把当前token前面不属于同一个doc的token对应的attention_mask设置成0即可,不同doc通过eos即可区分。
qibao77 commented
只需要把当前token前面不属于同一个doc的token对应的attention_mask设置成0即可,不同doc通过eos即可区分。
@ganzhiruyi
但是这种方式生成的attention_mask是不是不能用flash attention呀?或者说自己改flash attention?
ganzhiruyi commented
可以用flash attention triton