-
Notifications
You must be signed in to change notification settings - Fork 27.7k
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
[VITS] Add to TTA pipeline #25906
[VITS] Add to TTA pipeline #25906
Conversation
if self.model.can_generate(): | ||
output = self.model.generate(**model_inputs, **kwargs) | ||
else: | ||
output = self.model(**model_inputs, **kwargs)[0] |
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.
If we generate, we return a torch tensor as our output.
If we do a forward pass, we return an instance of ModelOutput
, where the 0-th element is our generated waveform
Hence, we slice here with [0]
to get our waveform output
The documentation is not available anymore as the PR was closed or merged. |
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.
LGTM ! Thanks for adding this model and correcting the forward case!
Co-authored-by: Yoach Lacombe <[email protected]>
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.
LGTM thanks !
# Conflicts: # tests/pipelines/test_pipelines_text_to_audio.py
* [VITS] Add to TTA pipeline * Update tests/pipelines/test_pipelines_text_to_audio.py Co-authored-by: Yoach Lacombe <[email protected]> * remove extra spaces --------- Co-authored-by: Yoach Lacombe <[email protected]>
What does this PR do?
Small changes to the TTA pipeline to allow for the VITS model