Skip to content
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

Add pad_silence option to extend_by #816

Merged
merged 2 commits into from
Sep 22, 2022
Merged

Conversation

desh2608
Copy link
Collaborator

This address #779.

Currently, the extend_by() method only extends the cut to at most the boundaries of the recording. With this option set to true, we can now pad with silence to extend beyond the recording's boundaries.

@desh2608 desh2608 added the enhancement New feature or request label Sep 22, 2022
pzelasko
pzelasko previously approved these changes Sep 22, 2022
Copy link
Collaborator

@pzelasko pzelasko left a comment

Choose a reason for hiding this comment

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

Great work, thanks!! Do you think it maybe makes sense to enable this option by default? Based on the issue (our single data point about user expectations) it looks like the users might expect that behavior by default.

@desh2608
Copy link
Collaborator Author

desh2608 commented Sep 22, 2022

Great work, thanks!! Do you think it maybe makes sense to enable this option by default? Based on the issue (our single data point about user expectations) it looks like the users might expect that behavior by default.

Yeah, I suppose that makes sense. I'll make the change.

(It might be worth explicitly pointing out this change in behavior in the next release's changelog, in case others are using the method. I know I am using it in one of my projects.)

@pzelasko pzelasko added this to the v1.8 milestone Sep 22, 2022
@pzelasko
Copy link
Collaborator

The unit test fail is a random flake, merging. Thanks!

@pzelasko pzelasko merged commit 4e6eca4 into lhotse-speech:master Sep 22, 2022
@desh2608 desh2608 deleted the pad_sil branch September 22, 2022 19:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants