13.1. Configuration Reference
Complete reference for all YAML configuration options in Tiny ML Tensorlab.
13.1.1. Configuration File Structure
common:
# General settings
dataset:
# Dataset configuration
data_processing_feature_extraction:
# Feature extraction settings
training:
# Training parameters
testing:
# Testing configuration
compilation:
# Compilation settings
13.1.2. Common Section
General project settings.
common:
target_module: 'timeseries' # 'timeseries' or 'image'
task_type: 'generic_timeseries_classification'
target_device: 'F28P55'
run_name: '{date-time}/{model_name}'
Option |
Required |
Description |
|---|---|---|
|
Yes |
Module type: |
|
Yes |
Task type (see below) |
|
Yes |
Target MCU device name |
|
No |
Output directory name pattern |
Task Types:
generic_timeseries_classificationgeneric_timeseries_regressiongeneric_timeseries_forecastinggeneric_timeseries_anomalydetectiongeneric_image_classificationbyom_compilation
Target Devices:
C2000: F28P55, F28P65, F29H85, F29P58, F29P32, F2837, F28004, F28003, F280013, F280015
MSPM0: MSPM0G3507, MSPM0G3519, MSPM0G5187
MSPM33C: MSPM33C32, MSPM33C34, AM13E2
AM26x: AM263, AM263P, AM261
Connectivity: CC2755, CC1352
13.1.3. Dataset Section
dataset:
enable: True
dataset_name: 'my_dataset'
input_data_path: '/path/to/dataset'
data_split_type: 'random'
data_split_ratio: [0.8, 0.1, 0.1]
Option |
Default |
Description |
|---|---|---|
|
True |
Enable dataset processing |
|
Required |
Dataset identifier |
|
None |
Path to custom dataset |
|
‘random’ |
Split method: ‘random’, ‘sequential’, ‘predefined’ |
|
[0.8, 0.1, 0.1] |
Train/val/test split ratios |
|
‘amongst_files’ |
‘amongst_files’ or ‘within_files’ |
13.1.4. Feature Extraction Section
data_processing_feature_extraction:
feature_extraction_name: 'Generic_1024Input_FFTBIN_64Feature_8Frame'
variables: 1
gof_test: False
Option |
Default |
Description |
|---|---|---|
|
None |
Preset name (e.g., |
|
None |
List of data processing transforms: |
|
None |
List of feature extraction transforms (e.g., |
|
1 |
Number of input channels, or list of column indices/names |
|
None |
Samples per frame |
|
None |
Output features per frame after transform |
|
None |
Number of frames to concatenate |
|
None |
Stride between frames as a fraction |
|
None |
Original sampling rate (used with |
|
None |
Target sampling rate (used with |
|
None |
Scaling factor applied to input data |
|
None |
Offset added to input data |
|
None |
Frames to skip between selected frames |
|
None |
Enable bin normalization |
|
None |
Feature stacking mode: |
|
False |
Run Goodness of Fit test |
|
None |
Dict of class-to-gain-range for data augmentation |
|
False |
Store extracted feature data to disk |
|
False |
Use neural network for feature extraction |
Forecasting-Specific:
data_processing_feature_extraction:
data_proc_transforms:
- SimpleWindow
frame_size: 32
stride_size: 0.1
forecast_horizon: 2
variables: 1
target_variables:
- 0
13.1.5. Training Section
training:
enable: True
model_name: 'CLS_4k_NPU'
training_epochs: 30
batch_size: 256
learning_rate: 0.001
num_gpus: 0
Option |
Default |
Description |
|---|---|---|
|
True |
Enable training |
|
Required |
Model name from registry |
|
20 |
Number of training epochs |
|
256 |
Batch size for training |
|
0.001 |
Initial learning rate |
|
‘adam’ |
‘adam’, ‘sgd’, ‘adamw’ |
|
0.0001 |
Weight decay (L2 regularization) |
|
0 |
Number of GPUs (0 for CPU) |
|
4 |
Data loader workers |
|
42 |
Random seed |
Quantization Options:
training:
quantization: 2
quantization_method: 'QAT'
quantization_weight_bitwidth: 8
quantization_activation_bitwidth: 8
Option |
Default |
Description |
|---|---|---|
|
0 |
Quantization mode: |
|
None |
|
|
None |
Weight bit width: |
|
None |
Activation bit width: |
Learning Rate Scheduler:
training:
lr_scheduler: 'cosine'
lr_warmup_epochs: 5
Option |
Default |
Description |
|---|---|---|
|
None |
‘cosine’, ‘step’, ‘exponential’ |
|
0 |
Warmup epochs |
|
10 |
Epochs per step (step scheduler) |
|
0.1 |
LR decay factor |
13.1.6. Testing Section
testing:
enable: True
test_float: True
test_quantized: True
Option |
Default |
Description |
|---|---|---|
|
True |
Enable testing |
|
True |
Test float32 model |
|
True |
Test quantized model |
|
False |
Save prediction results |
|
False |
Save misclassified samples |
13.1.7. NAS Section
nas:
enable: True
search_type: 'multi_trial'
num_trials: 20
param_range: [500, 5000]
accuracy_target: 0.95
Option |
Default |
Description |
|---|---|---|
|
False |
Enable NAS |
|
‘multi_trial’ |
‘single_trial’, ‘multi_trial’ |
|
20 |
Architectures to evaluate |
|
[500, 5000] |
[min, max] parameters |
|
0.9 |
Minimum accuracy target |
|
True |
Enforce NPU constraints |
13.1.8. Compilation Section
compilation:
enable: True
preset_name: 'compress_npu_layer_data'
Option |
Default |
Description |
|---|---|---|
|
True |
Enable compilation |
|
‘default_preset’ |
Compilation preset |
|
True |
Memory optimization |
|
False |
Include debug symbols |
Compilation Presets:
default_preset- Standard compilationcompress_npu_layer_data- NPU-optimized
13.1.9. BYOM Section
For compilation-only mode:
byom:
enable: True
onnx_model_path: '/path/to/model.onnx'
input_shape: [1, 1, 512, 1]
already_quantized: False
Option |
Default |
Description |
|---|---|---|
|
False |
Enable BYOM mode |
|
Required |
Path to ONNX model |
|
Required |
Model input shape |
|
False |
True if model is quantized |
13.1.10. Complete Example
common:
target_module: 'timeseries'
task_type: 'generic_timeseries_classification'
target_device: 'F28P55'
run_name: '{date-time}/{model_name}'
dataset:
enable: True
dataset_name: 'dc_arc_fault_example_dsk'
input_data_path: 'https://software-dl.ti.com/...'
data_split_type: 'random'
data_split_ratio: [0.8, 0.1, 0.1]
data_processing_feature_extraction:
enable: True
feature_extraction_name: 'FFT1024Input_256Feature_1Frame_Full_Bandwidth'
variables: 1
gof_test: False
training:
enable: True
model_name: 'ArcFault_model_400_t'
training_epochs: 30
batch_size: 256
learning_rate: 0.001
num_gpus: 0
quantization: 2
quantization_method: 'QAT'
quantization_weight_bitwidth: 8
quantization_activation_bitwidth: 8
testing:
enable: True
test_float: True
test_quantized: True
compilation:
enable: True
preset_name: 'compress_npu_layer_data'