Skip to main content

Hello everyone,

I'm new to the Axelera AI system and am currently working with a Metis PCIe card with 4 GB memory.

I want to understand how much of this memory is being used by the neural network model I am deploying. In a way, I'm looking for a tool or command that provides a report similar to what nvidia-smi does for NVIDIA GPUs, but for the Metis core.

From my research, I understand that the Metis core's DRAM is a fixed, dedicated resource and that the memory usage is determined at the time of compilation, not at runtime. I've heard that the Voyager SDK's compiler logs might contain this information.

My main question is: Where in the compiler output or log files can I find the exact memory footprint and percentage utilization for my model? Is there a specific argument or command I need to use to generate this report?

Any guidance on this would be greatly appreciated.

Thank you!

Hi, you are right that the memory usage is determined at compile time.

This gist can extract the info from the compiler model 

https://gist.github.com/sampartington/82b9ad9085972dce3c7f9eecc0a2e01d

 

For example

 

$ python axmodelinfo.py build/yolov8lseg-coco-onnx/yolov8lseg-coco-onnx/1/model.json
------------------------------------------------------------------------------
Pool Name Type Size Depth Has Init
------------------------------------------------------------------------------
pool_ddr DDR 3.62 MB (3,801,088) 1 No
pool_ddr_const DDR 65.75 MB (68,943,872) 1 Yes
pool_ddr_input DDR 3.21 MB (3,369,216) 2 No
pool_ddr_output DDR 7.23 MB (7,577,600) 2 No
pool_l2 L2 7.25 MB (7,602,176) 1 No
pool_l2_const L2 311.00 KB (318,464) 1 Yes
------------------------------------------------------------------------------

Summary:
---------------------------------------------
DDR : 79.81 MB (83,691,776)
L2 : 7.55 MB (7,920,640)
---------------------------------------------
TOTAL : 87.37 MB (91,612,416)
---------------------------------------------

 


Thanks so much for the help! The axmodelinfo.py command was exactly what I was looking for. The breakdown of the memory pools makes perfect sense now. I really appreciate you pointing me in the right direction.


Reply