-
Notifications
You must be signed in to change notification settings - Fork 31.7k
[mimi] mimi conv cache edge case #43130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
| self.per_layer_padding = per_layer_padding | ||
| self.per_layer_padding_mode = per_layer_padding_mode | ||
| self.per_layer_in_channels = per_layer_in_channels | ||
| self.per_layer_is_init = [True] * num_layers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is not used anywhere, let's remove
| torch.ones(batch_size, in_channels, padding, device=device, dtype=dtype) * hidden_states[..., :1] | ||
| ) | ||
| else: | ||
| raise NotImplementedError(f"Padding mode {padding_mode} not supported") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea to add _cache_init so that different models can initialize differently if needed
How about removing the check here inside init? Since you have a similar one in this new method?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree we could remove, but also it can be convenient to have raise an error at init to avoid having to run the full forward
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hum actually you're right, overwise it will be inconvenient and we'll have to also overwrite the init when working with other modes! thanks, removing
|
[For maintainers] Suggested jobs to run (before merge) run-slow: kyutai_speech_to_text, mimi |
What does this PR do?
two things;