Skip to content

Conversation

@rossarmstrong
Copy link
Contributor

Bug Fixes

  • Fixed IndexError in wer, wers, werp, werps, summary, and summaryp functions when processing single string inputs. The issue occurred due to incorrect handling of np.vectorize return values, which produce different array structures for single versus batch inputs (0-dimensional arrays for single strings, 1-dimensional object arrays for lists). The fix unwraps 0-dimensional arrays and uses element-type checking to distinguish between single example vectors and batch processing scenarios.

  • Improved handling of ragged data structures in batch processing by implementing direct field summation instead of transpose operations. This prevents errors when processing mixed scalar and list data in the word error rate breakdown results.

Enhancements

  • Added comprehensive benchmarking infrastructure to compare performance against werx and jiwer packages using the LibriSpeech evaluation dataset.

  • Added optional dependencies groups in pyproject.toml for testing and benchmarking workflows, enabling easier development environment setup.

@codecov
Copy link

codecov bot commented Dec 14, 2025

Codecov Report

❌ Patch coverage is 70.17544% with 51 lines in your changes missing coverage. Please review.
✅ Project coverage is 88.79%. Comparing base (7cc90e9) to head (b2c9836).

Files with missing lines Patch % Lines
werpy/summaryp.py 61.90% 16 Missing ⚠️
werpy/werps.py 63.15% 14 Missing ⚠️
werpy/werp.py 73.68% 10 Missing ⚠️
werpy/wer.py 80.00% 4 Missing ⚠️
werpy/wers.py 76.47% 4 Missing ⚠️
werpy/summary.py 81.25% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #37      +/-   ##
==========================================
- Coverage   92.21%   88.79%   -3.43%     
==========================================
  Files          16       16              
  Lines         347      464     +117     
==========================================
+ Hits          320      412      +92     
- Misses         27       52      +25     
Flag Coverage Δ
unittests 88.79% <70.17%> (-3.43%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@rossarmstrong rossarmstrong merged commit 9845f18 into main Dec 14, 2025
9 of 14 checks passed
@rossarmstrong rossarmstrong deleted the development branch December 14, 2025 12:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants