drop unused

This commit is contained in:
bel
2024-01-01 18:41:49 -07:00
parent 86bb1769f3
commit 871efd9b8c
2 changed files with 0 additions and 171 deletions

View File

@@ -263,19 +263,6 @@ impl Engine {
}
}
struct Engine2 {
}
fn new_engine_2() -> Result<Engine2, String> {
Ok(Engine2{})
}
impl Engine2 {
fn transcribe(&self, data: &Vec<f32>) -> Result<Transcribed, String> {
Err(format!("not impl"))
}
}
struct ATranscribe {
data: Vec<f32>,
ack: Option<std::sync::mpsc::SyncSender<bool>>,
@@ -374,16 +361,4 @@ mod tests {
"../gitea-whisper-rs/sys/whisper.cpp/bindings/go/samples/jfk.wav".to_string(),
);
}
#[test]
fn test_transcribe_tiny_jfk_wav_candle() {
let wav_path = "../gitea-whisper-rs/sys/whisper.cpp/bindings/go/samples/jfk.wav".to_string();
let audio_data = f32_from_wav_file(&wav_path).unwrap();
let engine = new_engine_2().unwrap();
let result = engine.transcribe(&audio_data);
assert_eq!(
" And so my fellow Americans ask not what your country can do for you ask what you can do for your country.".to_string(),
result.unwrap().to_string(),
);
}
}