Skip to content

Commit

Permalink
v0.15.0: update rustpotter
Browse files Browse the repository at this point in the history
  • Loading branch information
GiviMAD committed Jun 9, 2022
1 parent f79d901 commit ada2232
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 18 deletions.
6 changes: 3 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
[package]
name = "rustpotter-cli"
version = "0.14.4"
version = "0.15.0"
edition = "2021"
license = "Apache-2.0"
description = "CLI for Rustpotter, an open source wake word spotter forged in rust"
authors = ["Miguel Álvarez Díez <[email protected]>"]
repository = "https://github.com/GiviMAD/rustpotter"

[dependencies]
rustpotter = { version = "0.14.4", features = ["log", "vad"] }
rustpotter = { version = "0.15.0", features = ["log", "vad"] }
log = "0.4.6"
pv_recorder = "1.0.2"
ctrlc = "3.2.2"
Expand Down
13 changes: 0 additions & 13 deletions src/cli/spot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ pub struct SpotCommand {
/// Enables eager mode
eager_mode: bool,
#[clap(long)]
/// Enables training mode, the word will be persisted on the current directory
training_mode: bool,
#[clap(long)]
/// Unless enabled the comparison against multiple wakewords run in separate threads, not applies when single wakeword
single_thread: bool,
#[clap(short = 'n', long, possible_values = ["easiest", "easy", "normal", "hard", "hardest"])]
Expand Down Expand Up @@ -76,7 +73,6 @@ pub fn spot(command: SpotCommand) -> Result<(), String> {
.set_threshold(command.threshold)
.set_sample_rate(16000)
.set_eager_mode(command.eager_mode)
.set_eager_mode(command.training_mode)
.set_single_thread(command.single_thread)
.build();
let mut wakeword_names: Vec<String> = Vec::new();
Expand Down Expand Up @@ -121,15 +117,6 @@ pub fn spot(command: SpotCommand) -> Result<(), String> {
}
}
println!("Stopped by user request");
if command.training_mode {
println!("Generating trained wakeword files...");
for name in wakeword_names {
word_detector.generate_trained_wakeword_model_file(
name.clone(),
name.replace(" ", "_") + "_trained.rpw",
)?;
}
}
#[cfg(all(feature = "dist", not(target_os = "windows")))]
lib_temp_path.close().expect("Unable to remove temp file");
Ok(())
Expand Down

0 comments on commit ada2232

Please sign in to comment.