Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't seem to turn off logs #196

Closed
vlovich opened this issue Jan 26, 2025 · 5 comments
Closed

Can't seem to turn off logs #196

vlovich opened this issue Jan 26, 2025 · 5 comments

Comments

@vlovich
Copy link

vlovich commented Jan 26, 2025

I have the following params set which the docs indicate should turn off stdout/stderr noise:

        params.set_debug_mode(false);
        params.set_print_special(false);
        params.set_print_progress(false);
        params.set_print_realtime(false);
        params.set_print_timestamps(false);

but for some reason I'm still seeing output like the following on my terminal:

whisper_full_with_state: decoder 0 completed
whisper_full_with_state: decoder  0: score = -0.88475, result_len =  10, avg_logprobs = -0.88475, entropy =  2.16396
whisper_full_with_state: best decoder = 0
seek = 500, seek_delta = 500

whisper_full_with_state: strategy = 0, decoding with 1 decoders, temperature = 0.00


whisper_full_with_state: prompt[0] = [_SOT_]
whisper_full_with_state: prompt[1] = [_LANG_en]
whisper_full_with_state: prompt[2] = [_TRANSCRIBE_]


whisper_full_with_state: id =   0, decoder = 0, token =  50364, p =  0.722, ts =    [_BEG_],  0.722, result_len =    0 '[_BEG_]'
@tazz4843
Copy link
Owner

There is no way to disable all output. Upstream whisper.cpp offers very limited control over this. Your best best is capturing all output with one of the logging hooks included in the crate and disabling whisper.cpp logging entirely. Even then, if you're using one of the specialized compute backends, you will still get some logging printed to stdout/stderr.

@tazz4843
Copy link
Owner

Going to go ahead and close this as an upstream bug, feel free to reopen if you need more help.

@tazz4843 tazz4843 closed this as not planned Won't fix, can't repro, duplicate, stale Feb 10, 2025
@vlovich
Copy link
Author

vlovich commented Feb 10, 2025

@tazz4843 could you reconsider? I think ggml_log_set is all that needs to be called to intercept all log output & redirect it somewhere. utilityai/llama-cpp-rs#637 is an example of how to do this (llama.cpp has it's own additional logs but I believe whisper.cpp logs directly to ggml).

@tazz4843
Copy link
Owner

Oh my bad I thought we already did call this fn but clearly not. I'll take a stab at implementing it in a bit.

@tazz4843
Copy link
Owner

See #200

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants