This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TDA4VM: TDA4VM cannot work with Resnet50(1080p) properly

Part Number: TDA4VM

Hi, i'm trying test Resnet50(1080p) with TDA4VM, but sth went wrong.

i get error info like below, more memory space is needed.

[C7x_1 ] 834.739171 s: VX_ZONE_ERROR:[tivxAlgiVisionAllocMem:182] Failed to Allocate memory record 6 @ space = 17 and size = 336524160 !!!
[C7x_1 ] 834.739224 s: VX_ZONE_ERROR:[tivxAlgiVisionCreate:314] Calling ialg.algInit failed with status = -1111

i have also tested this model with "TIDL Graph Compiler".

it can work well if "MSMCSIZE_KB" increased to 9000.

any suggestions for dealing with this problem?  THX!

  • MSMCSIZE_KB cannot be 9000 on target but OK for host emulation mode.

    On target we only have a maximum of 8192 KB of MSMC RAM but about 256KB is reserved for other tasks like ATF and SYSFW, so please limit the MSMC size to (8192 - 256) KB 

    On the DDR side you seem to run out of scratch memory while allocating memory records. You will have to change the system memory map to accommodate these large requests. Please refer to this link to change system memory map,

    http://software-dl.ti.com/jacinto7/esd/processor-sdk-rtos-jacinto7/latest/exports/docs/psdk_rtos_auto/docs/user_guide/developer_notes_memory_map.html

  • Thanks for your helpful suggestions! The memory error has been resolved.

    But new error was foud like below.

    "

    [C7x_1 ] 639.770341 s: VX_ZONE_INFO:[tivxAlgiVisionCreate:304] Calling ialg.algInit ...
    [C7x_1 ] 639.770384 s: VX_ZONE_ERROR:[tivxAlgiVisionCreate:312] Calling ialg.algInit returned
    [C7x_1 ] 639.770406 s: VX_ZONE_ERROR:[tivxAlgiVisionCreate:315] Calling ialg.algInit failed with status = -1111

    "

    I can't find a status value which is -1111. What does it mean?

  • I have looped in an expert who might provide some clues. 

    Regards,
    Shyam

  • Hi,

       The error -1111 indicates that the model is generated without graph compiler/network compiler information. Can you share the logs you get when you import the model for TIDL.


    Regards,

    Anshu

  • THX!

    It seems that compiler need more memory space. How can i deal with this?

    The logs I get when import the model is as following.

    "

    Caffe Network File : ./caffe_models/ResNet/ResNet-50-deploy-1080p.prototxt
    Caffe Model File : ./caffe_models/ResNet/ResNet-50-model.caffemodel
    TIDL Network File : ./tidl_models/tidl_net_ResNet-50-1080p.bin
    TIDL IO Info File : ./tidl_models/tidl_io_ResNet-50-1080p_

    Name of the Network : ResNet-50
    gParams.numParamBits < 32
    quantize with TIDL_quantStatsFixedOrFloat
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    T
    Processing config file #0 : /home/horizon/TDA4_Files/TDA4_Test/tidl_models/tidl_import_ResNet-50-1080p.txt.qunat_stats_config.txt
    ----------------------- TIDL Process with REF_ONLY FLOW ------------------------

    # 0 . .. T 365095.95 ... .... .....
    # 1 . .. T 365921.80 ... .... .....
    # 2 . .. T 364912.16 ... .... .....
    # 3 . .. T 365736.39 ... .... .....Error : Error Code = <ERR_MMEORY_ALLOCATION, ERR_HIGHER_INSTANCEMEM>

    ------------------ Network Compiler Traces -----------------------------
    IDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias
    weightsElementSizeInBits <= 8
    TIDLPCLayers[i].layerParams.convParams.enableBias

    ~~~~~Running TIDL in PC emulation mode to collect Activations range for each layer~~~~~
    Could not open /home/horizon/TDA4_Files/TDA4_Test/tidl_models/ResNet-50-1080p/perfSimInfo.bin
    WARNING: [TIDL_E_DATAFLOW_INFO_NULL] ti_cnnperfsim.out fails to allocate memory in MSMC. Please look into perfsim log. This model can only be used on PC emulation, it will get fault on target.
    ****************************************************
    ** 1 WARNINGS 0 ERRORS **
    ****************************************************

    "

  • Hi,

        Can you tell which release version of TIDL you are using? 


    Regards,

    Anshu

  • I'm using tidl_j7_01_02_00_09 which is provided in the psdk_rtos_auto_j7_07_00_00_11 package.

  • Hi,   

      Fix for the following issue will be available as part of SDK 7.1.

        3 . .. T 365736.39 ... .... .....Error : Error Code = <ERR_MMEORY_ALLOCATION, ERR_HIGHER_INSTANCEMEM>

    Regards,

    Anshu