Skip to content

Commit

Permalink
Minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pkufool committed Jan 15, 2024
1 parent 29a1b2c commit 1912a46
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,7 @@ class MainActivity : AppCompatActivity() {
val status = model.reset(keywords)
if (!status) {
Log.i(TAG, "Failed to reset with keywords.")
val message = """Failed to setKeywords :\n ${keywords}, \n
The stream is not reset, \n
please change the keywords and try again."""
Toast.makeText(this, message, Toast.LENGTH_LONG).show();
Toast.makeText(this, "Failed to set keywords.", Toast.LENGTH_LONG).show();
}

recordingThread = thread(true) {
Expand Down Expand Up @@ -193,7 +190,7 @@ class MainActivity : AppCompatActivity() {
// Please change getModelConfig() to add new models
// See https://k2-fsa.github.io/sherpa/onnx/kws/pretrained_models/index.html
// for a list of available models
val type = 1
val type = 0
println("Select model type ${type}")
val config = KeywordSpotterConfig(
featConfig = getFeatureConfig(sampleRate = sampleRateInHz, featureDim = 80),
Expand Down

0 comments on commit 1912a46

Please sign in to comment.