mirror of
https://github.com/shirayu/whispering.git
synced 2024-06-12 18:29:21 +00:00
Fix
This commit is contained in:
parent
678aa92365
commit
8b5615cefa
|
@ -160,7 +160,7 @@ class WhisperStreamingTranscriber:
|
||||||
tokens[last_slice - 1].item() - self.tokenizer.timestamp_begin
|
tokens[last_slice - 1].item() - self.tokenizer.timestamp_begin
|
||||||
)
|
)
|
||||||
self.buffer_tokens.extend(tokens[: last_slice + 1].tolist())
|
self.buffer_tokens.extend(tokens[: last_slice + 1].tolist())
|
||||||
self.timestamp += last_timestamp_position * self.input_stride
|
self.timestamp += last_timestamp_position * self.time_precision
|
||||||
else:
|
else:
|
||||||
duration = segment_duration
|
duration = segment_duration
|
||||||
timestamps = tokens[timestamp_tokens.nonzero().flatten()]
|
timestamps = tokens[timestamp_tokens.nonzero().flatten()]
|
||||||
|
|
Loading…
Reference in a new issue