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

Support audio duration mismatch tolerance in MixedCut.load_audio() #1054

Merged
merged 5 commits into from
May 5, 2023

Conversation

pzelasko
Copy link
Collaborator

@pzelasko pzelasko commented May 4, 2023

No description provided.

@pzelasko pzelasko added this to the v1.15 milestone May 4, 2023
return mixture


def _create_mixture(
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is there a reason why this function is moved outside the class? The algorithm is specific to this particular simulator.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Makes sense, I changed this back and used the same "trick" as in the simulator.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Thanks. Could you do the same for _simulate_worker (i.e. make it a function of the specific class)? The logic for those is also tied to that algorithm.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That would complicate the workarounds for parallelization; anyway each simulation method has a separate file, so I think it should be OK and actually consistent with other functions in lhotse that are being parallelized this way, e.g. _X_single() functions at the end of lhotse/cut/set.py.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Okay, LGTM.

@pzelasko pzelasko enabled auto-merge May 5, 2023 12:45
@pzelasko pzelasko merged commit 6fcfced into master May 5, 2023
@pzelasko pzelasko deleted the feature/mixed-cut-audio-tolerance branch May 5, 2023 19:56
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