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.

  • Resolved

TDA2EXEVM: TIDL - tidlstasTool result matching

Part Number: TDA2EXEVM

Hello,

I am using TIDL ,and try the imagenet classification model inside the caffe-jacinto-models.

And i use the TIDL model import tool and get the result.

the input  rawsample data is a data inside the folder : ..\..\test\testvecs\input\preproc_0_224x224.y  which is a aircraft

But the output of the TIDLstatsTool is not the same as the the one i run the same models on the caffe-jacinto(the output of the caffe jacinto is class # 403)

but the output of the statsTool is class #704 (I open stats_tool_out.bin to get this result)

here is my TIDL model import tool config_files .

-------------------------------------------------------------------------------------

# Default - 0
randParams = 0

# 0: Caffe, 1: TensorFlow, Default - 0
modelType = 0

# 0: Fixed quantization By tarininng Framework, 1: Dyanamic quantization by TIDL, Default - 1
quantizationStyle = 1

# quantRoundAdd/100 will be added while rounding to integer, Default - 50
quantRoundAdd = 50

numParamBits = 8

#inNumChannels = 3

Cnov2dKernelType = 0

inputNetFile          = "..\..\test\testvecs\config\caffe_jacinto_models\trained\image_classification\imagenet_jacintonet11v2\sparse\deploy.prototxt"
inputParamsFile   = "..\..\test\testvecs\config\caffe_jacinto_models\trained\image_classification\imagenet_jacintonet11v2\sparse\imagenet_jacintonet_iter_160000.caffemodel"
outputNetFile        = "NET.BIN"
outputParamsFile = "PRM.BIN"

rawSampleInData = 1
#sampleInData = "..\..\test\testvecs\input\000100_1024x512_bgr.y"
sampleInData = "..\..\test\testvecs\input\preproc_0_224x224.y"
tidlStatsTool = "..\quantStatsTool\eve_test_dl_algo.out.exe"

----------------------------------------------------------------------------------------------------------------------------

also i test the segmentation model but the result seems to be wrong either.

Did i miss something? 

or what should i do to get the same result??

Thank you in advance.

  • Hello ,
    I use TIDLSRC.01.00.00.00.
    Does anyone know this problem or any suggestion?
  • Hello,
    Does anyone know this problem or any suggestion?
  • In reply to Eric Lai:

    Hi,

    I checked the TIDL model import tool config file that you used, looks like you missed setting "inElementType      = 0",  can you please check now by setting this.

    After setting "inElementType" to 0, new config file is

    -----------------------------------------------------------------------------

    # Default - 0
    randParams = 0

    # 0: Caffe, 1: TensorFlow, Default - 0
    modelType = 0

    # 0: Fixed quantization By tarininng Framework, 1: Dyanamic quantization by TIDL, Default - 1
    quantizationStyle = 1

    # quantRoundAdd/100 will be added while rounding to integer, Default - 50
    quantRoundAdd = 50

    numParamBits = 8

    #inNumChannels = 3

    # 0 : 8bit Unsigned, 1 : 8bit Signed Default - 1
    inElementType = 0

    conv2dKernelType = 0

    inputNetFile = "..\..\test\testvecs\config\caffe_jacinto_models\trained\image_classification\imagenet_jacintonet11v2\sparse\deploy.prototxt"
    inputParamsFile = "..\..\test\testvecs\config\caffe_jacinto_models\trained\image_classification\imagenet_jacintonet11v2\sparse\imagenet_jacintonet_iter_160000.caffemodel"
    outputNetFile = "NET.BIN"
    outputParamsFile = "PRM.BIN"

    rawSampleInData = 1
    #sampleInData = "..\..\test\testvecs\input\000100_1024x512_bgr.y"
    sampleInData = "..\..\test\testvecs\input\preproc_0_224x224.y"
    tidlStatsTool = "..\quantStatsTool\eve_test_dl_algo.out.exe"

    ---------------------------------------------------------------------------------------------------------------------------------------------------------------

    Sorry for the delay, we had long weekend here.

    Thanks,

    Praveen

  • In reply to Praveen Eppa:

    Hello Praveen,

    Thank you for your response.

    The result is reasonable now.

    Few more questions please,

    In the TIDL import configuration parameters:

    1. What is the meaning of dynamic quantization?

    2. What is the preProcType 0 to 3 stands for?

    3.In the TIDL import log , I want to know the exactly meaning of :

         1.Max PASS and values  

         2.The sec value of OUT Q

         3.The sec and third values of #MMACs

         4.The values of sparsity.    I know the definition of sparsity,but there are two values confusing me.

    Thank you!

    Regards,

    Eric

  • In reply to Eric Lai:

    Find the answers below:

    1.What is the meaning of dynamic quantization?

    Kumar: The Q formats/Scaling factor used for activation are selected dynamically at run-time.

    2. What is the preProcType 0 to 3 stands for?
    Kumar: This test tench specific for reading input image and resizing before giving to TIDL library. This can be ignored RAW image (RGB) is used

    3.In the TIDL import log , I want to know the exactly meaning of :
    Kumar : All the logs are for trace purpose, Some of them are not relevant for the final user.

    1.Max PASS and values
    Kumar : This Shall be ignored during import, this have meaning only during inference

    2.The sec value of OUT Q
    Kumar : Only first value is relevant Q of the output data. Second is debug info, can be ignored

    3.The sec and third values of #MMACs
    Kumar : Only first value is relevant. Second and third are debug info considering sparsity, can be ignored

    4.The values of sparsity. I know the definition of sparsity,but there are two values confusing me.
    Kumar : First value is sparsity considering actual processing computations. Second is sparsity considering available number of zero weights. These are different because of alignments during processing.

    Rgerads,
    Kumar.D
  • In reply to kumar.desappan:

    Thank you!

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.