File size: 2,549 Bytes
747451d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
general:
  project_name: tf_flowers
  logs_dir: logs
  saved_models_dir: saved_models
  global_seed: 127
  gpu_memory_limit: 5

operation_mode: chain_tqe

model:
  model_name: mobilenetv2_a035
  input_shape: (224, 224, 3)
  pretrained: True

dataset:
  dataset_name: tf_flowers
  class_names:
  - daisy
  - dandelion
  - roses
  - sunflowers
  - tulips
  training_path: image_classification/datasets/flower_photos
  validation_path: null
  validation_split: 0.2
  test_path: null
  quantization_path: null
  quantization_split: 0.2
  seed: 127

preprocessing:
  rescaling:
    scale: 1/127.5
    offset: -1
  resizing:
    interpolation: nearest
    aspect_ratio: fit
  color_mode: rgb

data_augmentation:
  random_contrast:
    factor: 0.6
  random_brightness:
    factor: 0.15
  random_rectangle_erasing:
    nrec: (0, 6)
    area: (0.0, 0.1)
    wh_ratio: (0.25, 4.0)
    fill_method: mosaic
    mode: batch
    change_rate: 0.05
  random_flip:
    mode: horizontal
  random_translation:
    width_factor: 0.3
    height_factor: 0.3
    fill_mode: wrap #reflect
    interpolation: nearest
  random_rotation:
    factor: 0.125
    fill_mode: wrap #reflect
    interpolation: nearest
  random_zoom:
    width_factor: 0.25
    height_factor: 0.25
    fill_mode: wrap #reflect
    interpolation: nearest
  random_shear:
    factor: 0.15
    fill_mode: wrap
    interpolation: nearest
  random_gaussian_noise:
    stddev: (0.0001, 0.005)

training:
  frozen_layers: None
  dropout: 0.9
  batch_size: 64
  epochs: 1000
  optimizer:
    Adam:
      learning_rate: 0.0001
  callbacks:
    ReduceLROnPlateau:
      monitor: val_accuracy
      patience: 30
      factor: 0.5
    EarlyStopping:
      monitor: val_accuracy
      mode: max
      restore_best_weights: true
      patience: 100

quantization:
  quantizer: TFlite_converter
  quantization_type: PTQ
  quantization_input_type: uint8
  quantization_output_type: float
  export_dir: quantized_models

tools:
  stedgeai:
    optimization: balanced
    on_cloud: True
    path_to_stedgeai: C:/ST/STEdgeAI/<x.y>/Utilities/windows/stedgeai.exe
  path_to_cubeIDE: C:/ST/STM32CubeIDE_<*.*.*>/STM32CubeIDE/stm32cubeide.exe

benchmarking:
  board: STM32H747I-DISCO

deployment:
  c_project_path: ../application_code/image_classification/
  IDE: GCC
  verbosity: 1
  hardware_setup:
    serie: STM32H7
    board: STM32H747I-DISCO
    input: SPI_CAMERA
    output: USB_DISPLAY

mlflow:
  uri: ./tf/src/experiments_outputs/mlruns

hydra:
  run:
    dir: ./tf/src/experiments_outputs/${now:%Y_%m_%d_%H_%M_%S}