Repository navigation
Preserve existing WAV files during video recognition - #244
Merged
Merged
Conversation
Signed-off-by: zhifu gao <zhifu.gzf@alibaba-inc.com>
This file contains hidden or 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
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.
A video named interview.mp4 previously extracted to interview.wav next to the input (or in the requested output directory). If that WAV already belonged to the user it was overwritten, then removed on successful decode. A decoder error could instead leave the substituted audio behind.
Use a per-call temporary directory, and release the video reader on failures while preserving the live handle for clipping on success. No changes to models, audio encoding, resampling or published releases.
Validation: all three regressions failed on the parent. The fixed source passed the full offline selection (119 passed, one optional live test skipped, repository-index test run separately). Actual generated H.264/AAC to MoviePy/FFmpeg to librosa produced identical 16,000 PCM samples before and after. Clipping the returned state produced the same 0.50-second video duration, sampled frame and SRT. Recognition was a fixture, not acoustic inference. No submitted/private media, model weights or hosted provider calls.