Skip to content

chore: log model load timings#24

Merged
MapleEve merged 3 commits intomainfrom
fix/model-load-timing
May 5, 2026
Merged

chore: log model load timings#24
MapleEve merged 3 commits intomainfrom
fix/model-load-timing

Conversation

@MapleEve
Copy link
Copy Markdown
Owner

@MapleEve MapleEve commented May 4, 2026

Summary

  • log elapsed lazy-load time for faster-whisper, pyannote diarization, WeSpeaker embedding, WhisperX alignment, and DeepFilterNet
  • keep model selection and loading behavior unchanged

Validation

  • ruff check app/ tests/unit/test_pipeline_model_lifecycle.py tests/unit/test_audio_layers.py tests/unit/test_provider_registry.py --ignore E501
  • ruff format --check app/ tests/unit/test_pipeline_model_lifecycle.py tests/unit/test_audio_layers.py tests/unit/test_provider_registry.py
  • targeted unit tests for faster-whisper / pyannote / WeSpeaker / WhisperX timing logs passed
  • public release scan passed

Note: one local DeepFilterNet test could not be collected on this machine because the host Python environment has incompatible NumPy/FastAPI artifacts; CI should run in a clean environment.

Copilot AI review requested due to automatic review settings May 4, 2026 01:52
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

👍 @MapleEve

Thank you for raising your pull request and contributing to voscript.
Please make sure you have followed our contributing guidelines. We will review it as soon as possible.
If you encounter any problems, please feel free to connect with us.
非常感谢您提出拉取请求并为 voscript 做出贡献,请确保您已经遵循了我们的贡献指南,我们会尽快审查它。
如果您遇到任何问题,请随时与我们联系。

@codecov
Copy link
Copy Markdown

codecov Bot commented May 4, 2026

Codecov Report

❌ Patch coverage is 92.00000% with 6 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (main@e4c7170). Learn more about missing BASE report.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
app/providers/voiceprint_match/default.py 50.00% 4 Missing ⚠️
app/application/transcription_jobs.py 33.33% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main      #24   +/-   ##
=======================================
  Coverage        ?   77.59%           
=======================================
  Files           ?       75           
  Lines           ?     2906           
  Branches        ?        0           
=======================================
  Hits            ?     2255           
  Misses          ?      651           
  Partials        ?        0           
Flag Coverage Δ
unit 77.59% <92.00%> (?)

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.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds elapsed-time logging around the pipeline’s lazy model loading paths to make it easier to spot slow startup/model initialization without changing model selection or device behavior.

Changes:

  • Log perf_counter()-based load durations for faster-whisper, pyannote diarization, and WeSpeaker embedding lazy-loads.
  • Log load duration for WhisperX alignment model load and DeepFilterNet init.
  • Add/adjust unit tests to assert the new timing log lines via caplog.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
app/pipeline/orchestrator.py Adds timing logs for faster-whisper / pyannote / WeSpeaker lazy-loads.
app/providers/diarization/default.py Adds timing log for WhisperX alignment model load (with context fields).
app/providers/enhance/default.py Adds timing log for DeepFilterNet lazy-load/init.
tests/unit/test_pipeline_model_lifecycle.py New assertions verifying orchestrator timing logs.
tests/unit/test_provider_registry.py Captures diarization logger output and asserts WhisperX alignment timing log.
tests/unit/test_audio_layers.py Adds DeepFilterNet timing log test using a stub df module.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@MapleEve MapleEve merged commit 7e5f81b into main May 5, 2026
8 checks passed
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 5, 2026

❤️ Great PR @MapleEve ❤️

The growth of project is inseparable from user feedback and contribution, thanks for your contribution!
项目的成长离不开用户反馈和贡献,感谢您的贡献!

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