Thanks for the inputs.
- We reran the optimization on an NVIDIA GPU.
model script -
normalization1 = normalization([0.0, 0.0, 0.0], [255.0, 255.0, 255.0])
change_output_activation(conv60, sigmoid)
change_output_activation(conv74, sigmoid)
change_output_activation(conv92, sigmoid)
quantization_param({output_layer*}, precision_mode=a16_w16)
allocator_param(automatic_reshapes=disabled)
model_optimization_flavor(optimization_level=2, compression_level=0, batch_size=1)
model_optimization_config(calibration, calibset_size=512)
Log snippet-
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
E0000 00:00:1794278624.575632 100276 cuda_dnn.cc:8310] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
E0000 00:00:1794278624.785896 100276 cuda_blas.cc:1418] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
e[36m Start run for network yolov11n_seg ...e[0m
e[36m Initializing the hailo8 runner...e[0m
e[36m Preparing calibration data...e[0m
[info] Loading model script commands to yolov11n_seg from /mnt/data3/dust/runs/yolo11n_seg_mzref_outputs_a16_calib512_20261110/yolov11n_seg_mzref_outputs_a16_calib512.alls
[info] Found model with 3 input channels, using real RGB images for calibration instead of sampling random data.
[info] Starting Model Optimization
I0000 00:00:1794278653.287958 100276 gpu_device.cc:2022] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1528 MB memory: -> device: 0, name: NVIDIA A10-4Q, pci bus id: 0002:00:00.0, compute capability: 8.6
I0000 00:00:1794278655.331400 100276 gpu_device.cc:2022] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1528 MB memory: -> device: 0, name: NVIDIA A10-4Q, pci bus id: 0002:00:00.0, compute capability: 8.6
[info] Model received quantization params from the hn
I0000 00:00:1794278657.417700 100276 gpu_device.cc:2022] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1528 MB memory: -> device: 0, name: NVIDIA A10-4Q, pci bus id: 0002:00:00.0, compute capability: 8.6
I0000 00:00:1794278657.780459 100276 gpu_device.cc:2022] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1528 MB memory: -> device: 0, name: NVIDIA A10-4Q, pci bus id: 0002:00:00.0, compute capability: 8.6
[info] MatmulDecompose skipped
[info] Starting Mixed Precision
[info] Model Optimization Algorithm Mixed Precision is done (completion time is 00:00:00.87)
[info] LayerNorm Decomposition skipped
[info] Starting Statistics Collector
[info] Using dataset with 512 entries for calibration
The optimization log confirms GPU detection, 512 calibration entries, level-2 processing and Quantization-Aware Fine-Tuning.
The calibration images were selected from our 7,350-image mining-dust dataset. This is the same deployment domain as the production application and includes relevant dust conditions, mining backgrounds, viewpoints and lighting variations. No generic COCO or other out-of-domain images were used.
The images were supplied as raw RGB values in the 0–255 range. They were not pre-normalized. The following normalization remained inside the model script:
normalization1 = normalization([0.0, 0.0, 0.0], [255.0, 255.0, 255.0]).
We used calibset_size=512 as recommended to reduce calibration-statistics runtime. It was not selected as an outlier-free or accuracy-optimized subset. Previous experiments with 512 versus the larger calibration set showed little accuracy difference, so calibration-set size does not appear to be the primary cause of the remaining quantization gap.
We evaluated the resulting HAR on a separate matched set of 1,059 dust-domain images. After level-2 optimization using 512 domain-specific calibration images, a quantization-related accuracy gap remained.
SDK_NATIVE and SDK_FP_OPTIMIZED produced effectively identical results, confirming that preprocessing and floating-point model translation were correct.
However, SDK_QUANTIZED still showed a recall loss:
SDK_FP_OPTIMIZED: Pixel recall: 67.77% Pixel IoU: 49.68% Region recall: 32.65%SDK_QUANTIZED: Pixel recall: 56.94% Pixel IoU: 45.21% Region recall: 27.06%
2)We have run analyze-noise both on advanced as well as simple mode with the following model script .alls
*normalization1 = normalization([0.0, 0.0, 0.0], [255.0, 255.0, 255.0])
change_output_activation(conv60, sigmoid)
change_output_activation(conv74, sigmoid)
change_output_activation(conv92, sigmoid)
allocator_param(automatic_reshapes=disabled)
model_optimization_flavor(optimization_level=2, compression_level=0, batch_size=1)
model_optimization_config(calibration, calibset_size=512)
model_optimization_config(
checker_cfg,
policy=enabled,
dataset_size=16,
batch_size=1,
analyze_mode=advanced
)
*
same issue -
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
E0000 00:00:1794335183.602539 1436183 cuda_dnn.cc:8310] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
E0000 00:00:1794335183.606771 1436183 cuda_blas.cc:1418] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
[info] Current Time: 18:26:27, 11/10/26
[info] CPU: Architecture: x86_64, Model: AMD EPYC 74F3 24-Core Processor, Number Of Cores: 6, Utilization: 0.8%
[info] Memory: Total: 53GB, Available: 51GB
[info] System info: OS: Linux, Kernel: 6.8.0-1015-azure
[info] Hailo DFC Version: 3.34.0
[info] HailoRT Version: Not Installed
[info] PCIe: No Hailo PCIe device was found
[info] Running hailo analyze-noise /mnt/data3/dust/runs/yolo11n_seg_mzref_no_a16_calib512_noise_20261110/yolov11n_seg.har --data-path /mnt/data3/dust/runs/yolo11n_seg_mzref_outputs_a16_no_softmax_batch1_retry1_20261109/noise_input_npy --batch-size 1 --data-count 128 --analyze-mode advanced
I0000 00:00:1794335194.289731 1436183 gpu_device.cc:2022] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1528 MB memory: -> device: 0, name: NVIDIA A10-4Q, pci bus id: 0002:00:00.0, compute capability: 8.6
[info] Starting Layer Noise Analysis
Full Quant Analysis: 0%| | 0/128 [00:00<?, ?iterations/s]Traceback (most recent call last):
File "/home/subnath/hailo_venv/bin/hailo", line 6, in
sys.exit(main())
^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/tools/cmd_utils/main.py", line 111, in main
ret_val = client_command_runner.run()
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/tools/cmd_utils/base_utils.py", line 68, in run
return self._run(argv)
^^^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/tools/cmd_utils/base_utils.py", line 89, in _run
return args.func(args)
^^^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/tools/hailo_lat_cli.py", line 60, in run
runner.analyze_noise(
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_common/states/states.py", line 16, in wrapped_func
return func(self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/runner/client_runner.py", line 2136, in analyze_noise
self.analyze_noise(
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_common/states/states.py", line 16, in wrapped_func
return func(self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/runner/client_runner.py", line 2158, in analyze_noise
return self.sdk_backend.run_layer_analysis_tool(data, data_count, batch_size, analyze_mode, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_sdk_client/sdk_backend/sdk_backend.py", line 1114, in run_layer_analysis_tool
analyzer.run()
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/optimization_algorithm.py", line 55, in run
return super().run()
^^^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/algorithm_base.py", line 159, in run
self.run_int()
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/hailo_layer_noise_analysis.py", line 86, in run_int
self.analyze_full_quant_net()
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/hailo_layer_noise_analysis.py", line 217, in analyze_full_quant_net
predict_function(inputs)
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/tensorflow/python/util/traceback_utils.py", line 153, in error_handler
raise e.with_traceback(filtered_tb) from None
File "/mnt/data3/dust/runs/yolo11n_seg_mzref_no_a16_calib512_noise_20261110/tmp/autograph_generated_filebkc2tu2f.py", line 13, in tf__predict_function
retval = ag.converted_call(ag.ld(lat_model), (ag.ld(data),), dict(training=False), fscope)
^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/keras/src/utils/traceback_utils.py", line 122, in error_handler
raise e.with_traceback(filtered_tb) from None
^^^^^^^^^^^
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/lat_utils/lat_model.py", line 423, in call
metric.update_state(native, numeric, partial_numeric=partial_numeric)
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/lat_utils/lat_model.py", line 23, in update_state
self.noise_energy.assign_add(tf.reduce_mean((native - numeric) ** 2))
~^~~
ValueError: in user code:
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/hailo_layer_noise_analysis.py", line 211, in predict_function *
return lat_model(data, training=False)
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/keras/src/utils/traceback_utils.py", line 122, in error_handler **
raise e.with_traceback(filtered_tb) from None
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/lat_utils/lat_model.py", line 423, in call
metric.update_state(native, numeric, partial_numeric=partial_numeric)
File "/home/subnath/hailo_venv/lib/python3.12/site-packages/hailo_model_optimization/algorithms/lat_utils/lat_model.py", line 23, in update_state
self.noise_energy.assign_add(tf.reduce_mean((native - numeric) ** 2))
ValueError: Exception encountered when calling LATModel.call().
e[1mDimensions must be equal, but are 64 and 66 for '{{node lat_model_1/sub_295}} = Sub[T=DT_FLOAT](lat_model_1/conv_feature_splitter6_2_1/act_op_1/Identity, lat_model_1/conv_feature_splitter6_2_3/output_op_1/mul)' with input shapes: [1,1,400,64], [1,1,400,66].e[0m
Arguments received by LATModel.call():
• inputs=tf.Tensor(shape=(1, 640, 640, 3), dtype=float32)
Full Quant Analysis: 0%| | 0/128 [00:52<?, ?iterations/s]