Skip to content

Commit a71bb5a

Browse files
committed
Fix bug in mamba2_simple slow path conv1d #393
1 parent c0a00bd commit a71bb5a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

mamba_ssm/modules/mamba2_simple.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@ def forward(self, u, seq_idx=None):
167167
xBC = self.act(
168168
self.conv1d(xBC.transpose(1, 2)).transpose(1, 2)
169169
) # (B, L, self.d_inner + 2 * ngroups * d_state)
170+
xBC = xBC[:, :seqlen, :]
170171
else:
171172
xBC = causal_conv1d_fn(
172173
x=xBC.transpose(1, 2),

0 commit comments

Comments
 (0)