mirror of
https://github.com/shirayu/whispering.git
synced 2024-11-25 10:21:00 +00:00
Add debug log
This commit is contained in:
parent
12cd9a4f42
commit
92d50a1c95
2 changed files with 4 additions and 2 deletions
|
@ -42,7 +42,7 @@ def transcribe_from_mic(
|
|||
):
|
||||
idx: int = 0
|
||||
while True:
|
||||
logger.debug(f"Segment #: {idx}, Queue: {q.qsize()}")
|
||||
logger.debug(f"Segment #: {idx}, The rest of queue: {q.qsize()}")
|
||||
segment = q.get()
|
||||
for chunk in wsp.transcribe(segment=segment):
|
||||
print(f"{chunk.start:.2f}->{chunk.end:.2f}\t{chunk.text}")
|
||||
|
|
|
@ -109,7 +109,9 @@ class WhisperStreamingTranscriber:
|
|||
and result.avg_logprob < self.config.logprob_threshold
|
||||
for result in results
|
||||
]
|
||||
logger.debug(f"Fall back with temperature: {t}, {needs_fallback}")
|
||||
logger.debug(
|
||||
f"Fall back with temperature: {t}, needs_fallback: {needs_fallback}"
|
||||
)
|
||||
if any(needs_fallback):
|
||||
_decode_options2: DecodingOptions = self._get_decoding_options(
|
||||
t=t,
|
||||
|
|
Loading…
Reference in a new issue