How madhesh666/voice_activation_systemm works
This repository supports a keyword-activation model workflow: record positive examples, preprocess positive and negative audio, extract MFCC features, assemble labeled data, train a DS-CNN, then quantize and export it as a C array. The README gives no further product details, and no firmware or end-to-end inference implementation is shown in the sampled source; the graph therefore stops at model export and treats the audio/model test scripts as standalone utilities.
Main entry points: prepare_dataset.py Labeled dataset · train_dscnn.py DS-CNN training · convert_int8.py INT8 conversion · X.npy Features X
Components 21
Audio capture
- Positive capture
collect_positive.py - Positive WAVs
- Keyword recording
record_keyword.py - Keyword WAV
keyword.wav
Feature preparation
- Positive preprocessing
preprocess_audio.py - Negative preprocessing
preprocess_negative.py - Positive MFCCs
extract_mfcc.py - Negative MFCCs
extract_mfcc_negative.py - Labeled dataset
prepare_dataset.py - Features X
X.npy - Labels y
y.npy
Model development
- DS-CNN training
train_dscnn.py - Keras model
dscnn_model.keras
Deployment export
- INT8 conversion
convert_int8.py - INT8 TFLite model
dscnn_model_int8.tflite - C array export
model_to_c_array.py - Embedded model header
dscnn_model_int8.h
Other components
- Speaker
- Audio test utility
test_audio.py - INT8 test utility
test_int8_model.py - Microphone test
mic_test.py
Connections 18
- Speaker → Positive capture: speaks samples
- Positive capture → Positive WAVs: writes WAVs
- Speaker → Keyword recording: speaks keyword
- Keyword recording → Keyword WAV: writes WAV
- Positive preprocessing → Positive MFCCs: prepares input
- Negative preprocessing → Negative MFCCs: prepares input
- Positive MFCCs → Labeled dataset: loads features
- Negative MFCCs → Labeled dataset: loads features
- Labeled dataset → Features X: writes features
- Labeled dataset → Labels y: writes labels
- DS-CNN training → Features X: loads features
- DS-CNN training → Labels y: loads labels
- DS-CNN training → Keras model: saves model
- INT8 conversion → Keras model: loads model
- INT8 conversion → Features X: calibrates with
- INT8 conversion → INT8 TFLite model: writes model
- C array export → INT8 TFLite model: reads model
- C array export → Embedded model header: writes header