Pass aheads by reference, add dtw_mem_size param, rustfmt

This commit is contained in:
arizhih 2024-05-17 02:05:12 +02:00
parent da6b410439
commit 482860d0d6
5 changed files with 45 additions and 37 deletions

View file

@ -7,7 +7,7 @@ use whisper_rs::{FullParams, SamplingStrategy, WhisperContext, WhisperContextPar
// more dependencies than the base library.
pub fn usage() -> Result<(), &'static str> {
// load a context and model
let ctx = WhisperContext::new_with_params("path/to/model", &mut WhisperContextParameters::default())
let ctx = WhisperContext::new_with_params("path/to/model", WhisperContextParameters::default())
.expect("failed to load model");
// make a state
let mut state = ctx.create_state().expect("failed to create state");