-
Notifications
You must be signed in to change notification settings - Fork 408
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
Ignore the NoUtterancesError
when calculating pesq for a batch
#2753
Merged
SkafteNicki
merged 15 commits into
Lightning-AI:master
from
veera-puthiran-14082:fix_pesq_nan
Oct 9, 2024
Merged
Ignore the NoUtterancesError
when calculating pesq for a batch
#2753
SkafteNicki
merged 15 commits into
Lightning-AI:master
from
veera-puthiran-14082:fix_pesq_nan
Oct 9, 2024
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
veera-puthiran-14082
requested review from
SkafteNicki,
Borda,
justusschock and
stancld
as code owners
September 17, 2024 11:41
veera-puthiran-14082
changed the title
Closes #2752
Ignores the NoUtterancesError when calculating pesq for a batch
Sep 17, 2024
veera-puthiran-14082
changed the title
Ignores the NoUtterancesError when calculating pesq for a batch
Ignore the NoUtterancesError when calculating pesq for a batch
Sep 17, 2024
Borda
changed the title
Ignore the NoUtterancesError when calculating pesq for a batch
Ignore the Sep 17, 2024
NoUtterancesError
when calculating pesq for a batch
Borda
approved these changes
Sep 17, 2024
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2753 +/- ##
========================================
- Coverage 69% 35% -34%
========================================
Files 329 316 -13
Lines 18079 17919 -160
========================================
- Hits 12501 6291 -6210
- Misses 5578 11628 +6050 |
@Borda can this be merged ? Thanks in advance |
SkafteNicki
reviewed
Oct 8, 2024
SkafteNicki
approved these changes
Oct 9, 2024
Borda
pushed a commit
that referenced
this pull request
Oct 9, 2024
* filter nan * use np * fix tests * fix dtype from object * as func * typing * changelog --------- Co-authored-by: Jirka Borovec <6035284+Borda@users.noreply.github.com> Co-authored-by: Nicki Skafte Detlefsen <skaftenicki@gmail.com> Co-authored-by: Jirka B <j.borovec+github@gmail.com> (cherry picked from commit 8cf181f)
Borda
pushed a commit
that referenced
this pull request
Oct 10, 2024
* filter nan * use np * fix tests * fix dtype from object * as func * typing * changelog --------- Co-authored-by: Jirka Borovec <6035284+Borda@users.noreply.github.com> Co-authored-by: Nicki Skafte Detlefsen <skaftenicki@gmail.com> Co-authored-by: Jirka B <j.borovec+github@gmail.com> (cherry picked from commit 8cf181f)
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.
What does this PR do?
Fixes #2752
Ignores the
NoUtterancesError
and create tensors with the available results, if a batch of size 32 is passed and 2 of them encountered an error, then for 30 pesq scores avg will be calculated and returned.introduced a simple lambda function which filter out exception messages and keep the pesq values calculated.
since the np.array contained error messages and pesq scores, the result was in np.object dtype. it is converted to np.float32 since pesq is also calculated in float32
Checklist
PR review
Anyone in the community is free to review the PR once the tests have passed.
If we didn't discuss your PR in Github issues there's a high chance it will not be merged.
📚 Documentation preview 📚: https://torchmetrics--2753.org.readthedocs.build/en/2753/