#define
macros found in model-parameters/model_metadata.h. Note that not all macros are listed--just the ones you'll probably care about.EI_CLASSIFIER_NN_INPUT_FRAME_SIZE
will be 320 * 320 * 3 = 307200. The trained machine learning model will expect this number of inputs.EI_CLASSIFIER_RAW_SAMPLE_COUNT
will equal 2 s * 100 Hz = 200 sample frames. For image data, this is the total number of pixels in the input image, which is equal to EI_CLASSIFIER_INPUT_WIDTH * EI_CLASSIFIER_INPUT_HEIGHT
.EI_CLASSIFIER_RAW_SAMPLES_PER_FRAME
is 3.EI_CLASSIFIER_RAW_SAMPLE_COUNT * EI_CLASSIFIER_RAW_SAMPLES_PER_FRAME
.1000 / EI_CLASSIFIER_FREQUENCY
. Set to 1 for image data.ei_classifier_inferencing_categories[]
, which is the number of classes that can be predicted by the classification model.1000 / EI_CLASSIFIER_INTERVAL_MS
. Set to 0 for image data.EI_CLASSIFIER_OBJECT_DETECTION
is set to 1, this macro is defined. Maximum number of objects that will be detected in each input image.EI_CLASSIFIER_OBJECT_DETECTION
is set to 1, this macro is defined. Only bounding boxes with confidence scores equal to or above this value will be returned from inference.EI_CLASSIFIER_OBJECT_DETECTION
is set to 1, this macro is defined. Set to 1 if constrained object detection model is used, 0 otherwise.EI_CLASSIFIER_TFLITE
, which uses TensorFlow Lite for Microcontrollers (TFLM) as the inference engine.EI_CLASSIFIER_NONE
EI_CLASSIFIER_UTENSOR
EI_CLASSIFIER_TFLITE
EI_CLASSIFIER_CUBEAI
EI_CLASSIFIER_TFLITE_FULL
EI_CLASSIFIER_TENSAIFLOW
EI_CLASSIFIER_TENSORRT
run_classifier_continuous()
to be called every 0.25 s and you have a window size of 1 s, EI_CLASSIFIER_SLICES_PER_MODEL_WINDOW
should be set to 4. It is set to 4 by default. Note that you can override this value in your main code if you #define
this macro prior to including the SDK. For example:EI_CLASSIFIER_RAW_SAMPLE_COUNT / EI_CLASSIFIER_SLICES_PER_MODEL_WINDOW
. For run_classifier_continouous()
applications, you can usually set signal.total_length
to EI_CLASSIFIER_SLICE_SIZE
. See this example.EI_CLASSIFIER_INFERENCING_ENGINE
is set to EI_CLASSIFIER_TFLITE
will force EI_CLASSIFIER_INFERENCING_ENGINE
to be set to EI_CLASSIFIER_TFLITE_FULL
. Not compatible with EON Compiler.