forked from NVIDIA/NeMo
-
Notifications
You must be signed in to change notification settings - Fork 1
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
Handling invalid audio generations (for DPO) #43
Merged
paarthneekhara
merged 6 commits into
paarthneekhara:experimentalt5tts_finalizedtransformer
from
rfejgin:experimentalt5tts_finalizedtransformer
Jan 30, 2025
Merged
Handling invalid audio generations (for DPO) #43
paarthneekhara
merged 6 commits into
paarthneekhara:experimentalt5tts_finalizedtransformer
from
rfejgin:experimentalt5tts_finalizedtransformer
Jan 30, 2025
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When the model generates an output that is very short (less than 2 ASR frames) the ASR and SSIM calculations will error out. We detect the error and invalidate the entire batch, setting WER/CER to 100% and SSIM to 0.0. The transcription is set to "<INVALID">. Note the metrics still written out to the `.metrics` files; they need to be ignored by any subsequent statistics calculations.
1. Skip groups that have any invalid records. 2. Allow the number of records to exactly match the number of audio files (vs requiring it to be strictly smaller). 3. Add `tqdm` to incidatea progress during long loops.
rfejgin
changed the title
Experimentalt5tts finalizedtransformer
Handling invalid audio generations (for DPO)
Jan 27, 2025
…former' into experimentalt5tts_finalizedtransformer
Refining the handling of invalid entries in DPO preference selection.
beep boop 🤖: 🚨 The following files must be fixed before merge! Your code was analyzed with PyLint. The following annotations have been identified:
Thank you for improving NeMo's documentation! |
paarthneekhara
merged commit Jan 30, 2025
d70b903
into
paarthneekhara:experimentalt5tts_finalizedtransformer
4 of 8 checks passed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When T5TTS generates an output audio that is very short (on the order of <1000 samples) this trips up the ASR and speaker similarity calculations. The ASR in particular needs at least two features' (frames) worth of samples.
Here, we detect the ASR error and write out invalid metrics for the entire batch, i.e. a WER/CER of
100%
, an SSIM of0.0
, and set the predicted transcript to<INVALID>
so that subsequent processing can process this entry as appropriate.For DPO preference pair creation we skip any record-group that has at least one entry with invalid metrics.
@shehzeen and @paarthneekhara could you review? @paarthneekhara please feel free to merge when ready. Thank you!