lhotse-speech / lhotse

Tools for handling speech data in machine learning projects.
https://lhotse.readthedocs.io/en/latest/
Apache License 2.0
908 stars 205 forks source link

Added handlings for negative end time (#1203) #1263

Open ArthLeu opened 6 months ago

ArthLeu commented 6 months ago

Formatted with Black this time.

desh2608 commented 6 months ago

Alignment times are supposed to be w.r.t. the recording, so I don't see how the start/end could be negative?

See: https://github.com/lhotse-speech/lhotse/blob/00896437da7df913fe8676836919c0f716d9a33b/lhotse/supervision.py#L40

pzelasko commented 6 months ago

@desh2608 Are we not adjusting alignment times together with supervision times when creating a cut?

@ArthLeu could you add a unit test that would have failed before but will pass correctly now to cover your changes?