ggerganov / whisper.cpp

Port of OpenAI's Whisper model in C/C++
MIT License
33.06k stars 3.31k forks source link

Trouble with language/detect_language and offset_ms params that are totally or partially ignored #1831

Open tripledee opened 5 months ago

tripledee commented 5 months ago

• Using a multilingual model (medium or largeV2) in C/ObjC, I noticed with numerous examples that despite defining a language in params.language and setting params.detect_language to false, whisper.cpp always auto detects the language and ignore both settings.

• So, as one of my recording test starts in french (~1 minute) and continues in German with absolutely no french speaking (the following ~30 minutes), I tried to delay the transcription, setting offset_ms param to 60000 ms. The transcript starts effectively from this one minute setting, but Whisper ignored it for language detection and still discovers french.

Any idea of what can explain these strange behaviours? Thanks

bobqianic commented 5 months ago

The offset_ms parameters do not ~impact the starting position for language detection~ shift position properly in master. We can fix it.

tripledee commented 5 months ago

Thanks for marking it as enhancement