MLBEDSW-5880 Fixed Vela verbose weight flag
*Original weights and encoded NPU weight now report correct size instead
of zero when running vela with --verbose-weights flag
(Code to update the aforementioned attributes was missing)
*Removed print references to unencoded NPU weight size
Change-Id: I6d3e41c04cc46d24eeb54cab89818a35e5df27be
Signed-off-by: Ayaan Masood <Ayaan.Masood@arm.com>
diff --git a/ethosu/vela/stats_writer.py b/ethosu/vela/stats_writer.py
index 86f531a..d8a274b 100644
--- a/ethosu/vela/stats_writer.py
+++ b/ethosu/vela/stats_writer.py
@@ -110,7 +110,6 @@
data_items += [midpoint_fps, nng.batch_size, midpoint_inference_time, n_passes, n_cascaded_passes]
data_items += [nng.memory_used.get(mem_area, 0) / 1024.0 for mem_area in mem_areas]
data_items += [nng.total_original_weights]
- data_items += [nng.total_npu_weights]
data_items += [nng.total_npu_encoded_weights]
for mem_area in mem_areas:
@@ -325,7 +324,6 @@
if weights_data:
print(f"Original Weights Size {weights_data['original'] / 1024.0:12.2f} KiB", file=f)
- print(f"NPU Weights Size {weights_data['npu'] / 1024.0:12.2f} KiB", file=f)
print(f"NPU Encoded Weights Size {weights_data['npu_encoded'] / 1024.0:12.2f} KiB", file=f)
print(file=f)
@@ -372,11 +370,7 @@
npu_operations.append(op)
weights_data = (
- {
- "original": nng.total_original_weights,
- "npu": nng.total_npu_weights,
- "npu_encoded": nng.total_npu_encoded_weights,
- }
+ {"original": nng.total_original_weights, "npu_encoded": nng.total_npu_encoded_weights}
if verbose_weights
else None
)