zhouhaoyi / Informer2020

The GitHub repository for the paper "Informer" accepted by AAAI 2021.
Apache License 2.0
5.24k stars 1.1k forks source link

mask中为什么使用了triu函数,而不是tril函数 #597

Open Jia-hn opened 8 months ago

Jia-hn commented 8 months ago

mask中使用triu函数导致上三角为True,也就是每个query只考虑之后key,而不是之前的key

2421468125 commented 7 months ago

没有错,FullAttention里把triu中为1的元素填充为-np.inf了