-
Notifications
You must be signed in to change notification settings - Fork 223
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
TypeError: slice indices must be integers or None or have an __index__ method #1001
Comments
https://github.com/lhotse-speech/lhotse/blob/master/lhotse/cut/base.py line 993-1019 for supervision in self.supervisions:
if (
use_alignment_if_exists
and supervision.alignment
and use_alignment_if_exists in supervision.alignment
):
for ali in supervision.alignment[use_alignment_if_exists]:
st = round(ali.start * self.sampling_rate) if ali.start > 0 else 0
et = (
round(ali.end * self.sampling_rate)
if ali.end < self.duration
else self.duration * self.sampling_rate
)
mask[st:et] = 1.0
else:
st = (
round(supervision.start * self.sampling_rate)
if supervision.start > 0
else 0
)
et = (
round(supervision.end * self.sampling_rate)
if supervision.end < self.duration
else self.duration * self.sampling_rate
)
mask[st:et] = 1.0
return mask |
Note that |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The text was updated successfully, but these errors were encountered: