mirror of
https://github.com/shirayu/whispering.git
synced 2024-11-25 10:21:00 +00:00
Add segment debug log
This commit is contained in:
parent
64060ee8b4
commit
6756893d95
1 changed files with 3 additions and 0 deletions
|
@ -40,10 +40,13 @@ def transcribe_from_mic(
|
|||
channels=1,
|
||||
callback=sd_callback,
|
||||
):
|
||||
idx: int = 0
|
||||
while True:
|
||||
logger.debug(f"Segment: {idx}")
|
||||
segment = q.get()
|
||||
for chunk in wsp.transcribe(segment=segment):
|
||||
print(f"{chunk.start:.2f}->{chunk.end:.2f}\t{chunk.text}")
|
||||
idx += 1
|
||||
|
||||
|
||||
def get_opts() -> argparse.Namespace:
|
||||
|
|
Loading…
Reference in a new issue