TinyTrainable
 
Loading...
Searching...
No Matches
InputSpeech Class Reference

InputSpeech inherits from Input. More...

#include <InputSpeech.h>

Inheritance diagram for InputSpeech:
Input

Public Member Functions

 InputSpeech ()
 constructor
 
virtual void setupInstrument (bool serialDebugging) override
 
virtual void setupSpeechModel (String sounds[3], const unsigned char *model=nullptr) override
 
virtual void identify () override
 
- Public Member Functions inherited from Input
virtual ~Input ()
 destructor
 
virtual void setupInstrument (bool serialDebugging)
 
virtual void identify ()
 
virtual void trainKNN (int k, int examplesPerClass, String objects[3])
 
virtual void setupGestureModel (String gestures[3], const unsigned char *model=nullptr)
 
virtual void gesturePrintHeader ()
 
virtual void gestureReadData ()
 
virtual void gestureSetAcceleration (float newVal)
 
virtual void gestureSetNumberSamples (int newVal)
 
virtual void setupSpeechModel (String sounds[3], const unsigned char *model=nullptr)
 

Private Attributes

const int NUM_SOUNDS = 3
 
String _sounds [3]
 
tflite::ErrorReporter * error_reporter = nullptr
 
const tflite::Model * model = nullptr
 
tflite::MicroInterpreter * interpreter = nullptr
 
TfLiteTensor * model_input = nullptr
 
FeatureProviderfeature_provider = nullptr
 
RecognizeCommandsrecognizer = nullptr
 
int32_t previous_time = 0
 
uint8_t tensor_arena [kTensorArenaSize]
 
int8_t feature_buffer [kFeatureElementCount]
 
int8_t * model_input_buffer = nullptr
 

Static Private Attributes

static constexpr int kTensorArenaSize = 10 * 1024
 

Additional Inherited Members

- Public Attributes inherited from Input
TinyTrainabletiny = nullptr
 pointer to a TinyTrainable instance
 

Detailed Description

InputSpeech inherits from Input.

Arduino

TinyTrainable

Input

for input microphone

for machine learning

from TinyML micro_speech

Constructor & Destructor Documentation

◆ InputSpeech()

InputSpeech::InputSpeech ( )

constructor

file

learning model

Member Function Documentation

◆ identify()

void InputSpeech::identify ( )
overridevirtual

Reimplemented from Input.

◆ setupInstrument()

void InputSpeech::setupInstrument ( bool  serialDebugging)
overridevirtual

Reimplemented from Input.

◆ setupSpeechModel()

void InputSpeech::setupSpeechModel ( String  sounds[3],
const unsigned char *  model = nullptr 
)
overridevirtual

Reimplemented from Input.

Member Data Documentation

◆ _sounds

String InputSpeech::_sounds[3]
private

◆ error_reporter

tflite::ErrorReporter* InputSpeech::error_reporter = nullptr
private

◆ feature_buffer

int8_t InputSpeech::feature_buffer[kFeatureElementCount]
private

◆ feature_provider

FeatureProvider* InputSpeech::feature_provider = nullptr
private

◆ interpreter

tflite::MicroInterpreter* InputSpeech::interpreter = nullptr
private

◆ kTensorArenaSize

constexpr int InputSpeech::kTensorArenaSize = 10 * 1024
staticconstexprprivate

◆ model

const tflite::Model* InputSpeech::model = nullptr
private

◆ model_input

TfLiteTensor* InputSpeech::model_input = nullptr
private

◆ model_input_buffer

int8_t* InputSpeech::model_input_buffer = nullptr
private

◆ NUM_SOUNDS

const int InputSpeech::NUM_SOUNDS = 3
private

◆ previous_time

int32_t InputSpeech::previous_time = 0
private

◆ recognizer

RecognizeCommands* InputSpeech::recognizer = nullptr
private

◆ tensor_arena

uint8_t InputSpeech::tensor_arena[kTensorArenaSize]
private

The documentation for this class was generated from the following files: