(self, x: Tensor, attn_bias=None, rope: Tensor = None)
| 89 | return q, k |
| 90 | |
| 91 | def forward(self, x: Tensor, attn_bias=None, rope: Tensor = None) -> Tensor: |
| 92 | qkv = self.qkv(x) |
| 93 | attn_v = self.compute_attention(qkv=qkv, attn_bias=attn_bias, rope=rope) |
| 94 | x = self.proj(attn_v) |
| 95 | x = self.proj_drop(x) |
| 96 | return x |
| 97 | |
| 98 | def forward_list(self, x_list, attn_bias=None, rope_list=None) -> List[Tensor]: |
| 99 | assert len(x_list) == len(rope_list) # should be enforced by the Block |
nothing calls this directly
no test coverage detected