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.

ORB Feature Detector/Extractor on DSP --> OpenCV vs. VLIB

Other Parts Discussed in Thread: AM5728

Hello TI E2E Community,

feel free to correct me if my following assumptions are wrong:

TI supports Open CV's T-API [1]. This means if calling e.g. ORB-feature-descriptor from Open CV this will be accelerated through OpenCL. This means if I use e.g AM5728, my function call to ORB-feature-descriptor will be executed on the C66x DSP.

On the other hand TI's VLIB 3.3.0.3 also provides an FAST/ORB implementation (function name VLIB_ORB_*) for C66x [2].

My question is: What is the difference between this two methods dealing with ORB features? Is there a way to find out which method is faster?

[1]: http://www.ti.com/processors/dsp/libraries/open-cv.html
[2]: http://software-dl.ti.com/libs/vlib/latest/index_FDS.html

Best regards,
  Daniel

  • Daniel,

    Let me first address the difference in the implementation. VLIB is a DSP only library and has been written in DSP assembly/intrinsic code to provide optimized performance on the C66x architecture. If you want to use this from the ARM then you will need to integrate this in OpenCL/IPC such that the DSP firmware will load and run on the DSP.

    OpenCV is an ARM + DSP implementation where the IO functions and most of the OpenCV functions other than the ones we have added DSP acceleration run on the ARM. For the ones that we have added on the DSP, we have internally linked OpenCL such that when the user tries to use those functions it will offload the processing functionality on the DSP. The algortihm code is essentially still using the C/C++ code that is in OpenCV and doesn`t contain additonal optimizations beyond the compiler optimization. This is described in more detail here:
    processors.wiki.ti.com/.../OpenCV

    Regards,
    Rahul
  • Hello Rahul,

    thank you very much for your fast and detailed answer. I would like to gain some Information on differences in performance regarding the two libs. The site you sent contains demo code:

     OpenCL on, canny
     BGR2GRAY  tdiff=12.064661 ms
     GaussBlur tdiff=5.948558 ms
     Canny     tdiff=5.788493 ms
     OpenCL off, canny
     BGR2GRAY  tdiff=4.158085 ms
     GaussBlur tdiff=2.989813 ms
     Canny     tdiff=9.780171 ms

    Is there a demo example like this one available for the C66x using VLIB? I would like to get an idea on the performance of VLIB compared to OpenCV/OpenCL.

    Best regards,
      Daniel

  • Daniel,

    The only VLIB benchmarks that I am aware of is included in the VLIB software package.  I am attaching the test report for your reference.

    VLIB_c66x_TestReport.html

    Note that these bench marks were obtained on the DSP core only so it doesn`t include inter processor communication numbers and the numbers to manage cache between heterogeneous cores so it cannot be used for true apples to apples comparison.

    Regards,

    Rahul

  • Hello Rahul,

    could you please explain the tables columns in short:

    - Opt Compute cyc/pt
    - NatC Compute cyc/pt
    - I/O cyc/pt
    - Opt Comp || IO cyc/pt

    How to translate from cyc to time? --> C66x 750 MHz?

    Best regards,
      Daniel

  • Opt Compute cyc/pt : Benchmark for Optimized C intrinsic implementation of the function 

    NatC Compute cyc/pt: Benchmark for natural C implementation of the function

    IO cyc/pt : Intended for communicating time taken by function when data is received from IO (sensor), this includes additional system level delays.

    The library doesn`t perform any IO latency measure measurements.as far as I can tell.

    TO translate to time: I would use the formula at the end of each table to get the cycle count for the function and  then multiply with time period of DSP clock as you mentioned. If the DSP is running at 750Mhz then [ time = cycles * (1/(750))  in microseconds.]Hope this helps.

    Regards,

    Regards,

    Rahul