whisper.cpp
whisper.cpp copied to clipboard
GGML_ASSERT when i run main
When i run main example, i always get assert:
main.exe -m models\ggml-small.bin -f samples\jfk.wav -t 8
whisper_init_from_file_no_state: loading model from 'models\ggml-small.bin'
whisper_model_load: loading model
whisper_model_load: n_vocab = 51865
whisper_model_load: n_audio_ctx = 1500
whisper_model_load: n_audio_state = 768
whisper_model_load: n_audio_head = 12
whisper_model_load: n_audio_layer = 12
whisper_model_load: n_text_ctx = 448
whisper_model_load: n_text_state = 768
whisper_model_load: n_text_head = 12
whisper_model_load: n_text_layer = 12
whisper_model_load: n_mels = 80
whisper_model_load: f16 = 1
whisper_model_load: type = 3
whisper_model_load: mem required = 608.00 MB (+ 16.00 MB per decoder)
whisper_model_load: adding 1608 extra tokens
whisper_model_load: model ctx = 464.56 MB
whisper_model_load: model size = 464.44 MB
whisper_init_state: kv self size = 15.75 MB
whisper_init_state: kv cross size = 52.73 MB
system_info: n_threads = 8 / 8 | AVX = 1 | AVX2 = 1 | AVX512 = 0 | FMA = 0 | NEON = 0 | ARM_FMA = 0 | F16C = 0 | FP16_VA = 0 | WASM_SIMD = 0 | BLAS = 0 | SSE3 = 0 | VSX = 0 |
main: processing 'samples\jfk.wav' (176000 samples, 11.0 sec), 8 threads, 1 processors, lang = en, task = transcribe, timestamps = 1 ...
GGML_ASSERT: C:\Users\a\whisper.cpp\ggml.c:2846: ((uintptr_t) (result->data))%GGML_MEM_ALIGN == 0
I have tried small.bin and medium.bin, different sounds (converted with ffmpeg) but I always get this error. What's wrong?
Platform: Windows 10 x64 Build type: Release Whisper was configured with CMake and built with Visual Studio 2017.
Version 1.2.1 works fine, but i needed make some changes for successful build:
- replace " restrict " to " __restrict " in ggml.c
- add #define M_PI 3.14159265358979323846 in whisper.cpp
- add #include
in whisper.cpp - add #include
to main.cpp and bench.cpp
It seems, that last version in repository doesn't work on Windows (i tested it on Ubuntu 22.04 x64, and it works fine)