state-spaces / mamba

Mamba SSM architecture
Apache License 2.0
13.39k stars 1.14k forks source link

Input output dimension #409

Open zyw0o1564 opened 5 months ago

zyw0o1564 commented 5 months ago

If the output dimension of the Mamba model doesn't necessarily equal the input dimension, how should I configure it? I am using the Mamba model where the input is 3-dimensional data and the output is also 3-dimensional, but I only want a 1-dimensional output.

tridao commented 5 months ago

In terms of dimensions Mamba is no different than MLP or Attention. So this question is not specific to Mamba. You can do whatever is standard in your task (taking mean, taking the first element, last element, etc.).