Difference between revisions of "GStreamer Based Image Signal Processor/Performance/imx8"

From RidgeRun Developer Connection
Jump to: navigation, search
(Summary)
m
 
(33 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
<noinclude>
 
<noinclude>
{{GStreamer Based Image Signal Processor/Head|previous=Performance/imx6|next=Performance/Color Space Conversion| keywords=}}
+
{{GStreamer Based Image Signal Processor/Head|previous=Performance/imx6|next=Troubleshoot|metakeywords=CSC Benchmarking, CPU usage, Memory usage, Execution time, Maximum Framerate, Debayer Benchmarking, Histogram Equalization Benchmarking, AWB Benchmarking}}
 
</noinclude>
 
</noinclude>
  
 +
== Benchmark environment ==
  
= CSC Benchmarking =
+
The following setup was used for all the benchmarks:
  
The following section describes some relevant performance measurements for the RGBA to NV12 color space conversion for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
+
*[https://www.nxp.com/design/development-boards/i.mx-evaluation-and-development-boards/evaluation-kit-for-the-i.mx-8m-applications-processor:MCIMX8M-EVK NXP® i.MX 8MQuad Evaluation Kit (EVK)]
 +
*Yocto built image (fsl-image-multimedia) from Freescale BSP
 +
*i.MX8 5640 RAW10 Camera Module
  
== Pipeline ==
+
=== GStreamer Bayer10 Support ===
 +
 
 +
GStreamer has support for 8-bit Bayer only. To enable 10-bit Bayer support, please, follow this [[CUDA_ISP_for_NVIDIA_Jetson/Getting_Started/Building_custom_v4l2src_element|wiki]].
 +
 
 +
== CSC Benchmarking ==
 +
 
 +
The following section describes some relevant performance measurements for the RGBA to NV12 color space conversion for a few standard resolutions. It begins with a summary of the results detailed in the following sections, as well as the pipelines used to capture such results.
 +
 
 +
=== Pipeline ===
  
 
All the measurements below were made using the following minimal pipeline.
 
All the measurements below were made using the following minimal pipeline.
Line 19: Line 30:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
== Summary ==
+
=== Summary ===
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the CSC algorithm.  
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the CSC algorithm.  
 
<html>
 
<html>
Line 27: Line 38:
 
     <th>Resolution</th>
 
     <th>Resolution</th>
 
     <th>CPU usage (%)</th>  
 
     <th>CPU usage (%)</th>  
     <th>Memory (kB)</th>
+
     <th>Memory Bandwidth (GHz)</th>
 
     <th>Execution Time (ms)</th>
 
     <th>Execution Time (ms)</th>
 
   </tr>
 
   </tr>
Line 33: Line 44:
 
     <td>640x480@30fps</td>
 
     <td>640x480@30fps</td>
 
     <td>4</td>
 
     <td>4</td>
     <td>18664</td>
+
     <td>1.020</td>
 
     <td>2.24</td>
 
     <td>2.24</td>
 
   </tr>
 
   </tr>
Line 39: Line 50:
 
     <td>1280x720@30fps</td>
 
     <td>1280x720@30fps</td>
 
     <td>10</td>
 
     <td>10</td>
     <td>19484</td>
+
     <td>1.034</td>
 
     <td>6.19</td>
 
     <td>6.19</td>
 
</tr>
 
</tr>
Line 45: Line 56:
 
     <td>1920x1080@30fps</td>
 
     <td>1920x1080@30fps</td>
 
     <td>14</td>
 
     <td>14</td>
     <td>21424</td>
+
     <td>1.466</td>
 
     <td>13.17</td>
 
     <td>13.17</td>
 
</tr>
 
</tr>
<caption>Table 1. Summary table regarding to the CSC performance for several standard resolutions running at 30fps</caption>
+
<caption>Table 1. Performance for several standard resolutions at 30fps</caption>
 
</table>
 
</table>
 
</center>
 
</center>
Line 72: Line 83:
 
     <td>55</td>
 
     <td>55</td>
 
</tr>
 
</tr>
<caption>Table 2. Summary table for the maximum framerate using CSC algorithm for several standard resolutions</caption>
+
<caption>Table 2. Maximum framerate at standard resolutions</caption>
 
</table>
 
</table>
 
</center>
 
</center>
 
</html>
 
</html>
  
<span style="color:red"> '''*Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture. </span>
+
<br>
 +
{{Ambox
 +
|type=notice
 +
|small=left
 +
|issue='''Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture.
 +
|style=width:unset;
 +
}}
 +
<br>
 +
 
 +
===CPU usage===
 +
These measurements were taken with the '''top''' app to monitor the behavior of the pipeline while running.
 +
 
 +
[[File:Cpu.png|frame|center|CPU usage for '''CSC''' element]]
 +
 
 +
===Memory usage===
 +
These measurements were taken with '''perf stat''' Linux tool to measure the bandwidth needed by the pipeline.
  
==CPU usage==
+
[[File:Memo.png|frame|center|Memory bandwidth consumption by '''CSC''' element]]
These measurements were taken with '''top''' app to monitor the behavior of the pipeline while running. Notice, however, that videotestsrc was used to generate the buffers and it consumes a lot of CPU, so it is likely the results will differ if a camera is used for capture.
 
[[File:Cpu.png|frame|center|CPU usage for CSC kernel.]]
 
  
==Memory usage==
+
===Execution time===
These measurements were taken with '''meminfo''' file to see the behavior of the pipeline while running, but it is important to consider that videotestsrc was used to generate the buffers.
+
These measurements were taken using some '''timestamps''' before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.  
[[File:Memo.png|frame|center|Memory consumption by CSC kernel.]]
 
  
==Execution time==
+
[[File:Extime.png|frame|center|Execution time for different resolutions with the '''CSC''' element]]
These measurements were taken using some '''timestamps''' before and after the processing to measure just the execution time for the CSC kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin. The image below shows the CSC execution time by each frame for each resolution.
 
[[File:Extime.png|frame|center|Execution time for different resolutions on the CSC kernel.]]
 
  
==Maximum Framerate==
+
===Maximum Framerate===
These measurements were taken with the '''gst-perf''' tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported. The image below shows the maximum framerate that the CSC element supports, which depends on the execution time of the CSC kernel algorithm.
+
These measurements were taken with the '''gst-perf''' tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.  
  
 
The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.
 
The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.
Line 102: Line 123:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
[[File:Framerate.png|frame|center|Framerate for different resolutions on the CSC kernel.]]
+
[[File:Framerate.png|frame|center|Framerate for different resolutions with the '''CSC''' element]]
  
=Debayer Benckmarking=
+
==Debayer Benckmarking==
  
 
The following section describes some relevant performance measurements during debayering for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
 
The following section describes some relevant performance measurements during debayering for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
  
== Pipeline ==
+
=== Pipeline ===
  
 
All the measurements below were made using the following minimal pipeline.
 
All the measurements below were made using the following minimal pipeline.
Line 116: Line 137:
 
HEIGHT=1080
 
HEIGHT=1080
  
gst-launch-1.0 v4l2src io-mode=userptr device=/dev/video1 ! video/x-bayer,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispcldebayer ! fakesink -v
+
$ gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-bayer,format=bggr,bpp=10,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispclbayer10to8 ! queue ! ispcldebayer ! fakesink -v
 
</syntaxhighlight>
 
</syntaxhighlight>
  
== Summary ==
+
=== Summary ===
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the debayer algorithm.  
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the debayer algorithm.  
 
<html>
 
<html>
Line 126: Line 147:
 
   <tr>
 
   <tr>
 
     <th>Resolution</th>
 
     <th>Resolution</th>
     <th>CPU usage (%) *</th>  
+
     <th>CPU usage (%)</th>  
     <th>Memory (kB) *</th>
+
     <th>Memory Bandwidth (GHz)</th>
 
     <th>Execution Time (ms)</th>
 
     <th>Execution Time (ms)</th>
 
   </tr>
 
   </tr>
Line 133: Line 154:
 
     <td>640x480@30fps</td>
 
     <td>640x480@30fps</td>
 
     <td>2</td>
 
     <td>2</td>
     <td>20084</td>
+
     <td>1.025</td>
 
     <td>3.54</td>
 
     <td>3.54</td>
 
   </tr>
 
   </tr>
Line 139: Line 160:
 
     <td>1280x720@30fps</td>
 
     <td>1280x720@30fps</td>
 
     <td>2</td>
 
     <td>2</td>
     <td>22564</td>
+
     <td>1.084</td>
 
     <td>9.89</td>
 
     <td>9.89</td>
 
</tr>
 
</tr>
Line 145: Line 166:
 
     <td>1920x1080@30fps</td>
 
     <td>1920x1080@30fps</td>
 
     <td>3</td>
 
     <td>3</td>
     <td>23212</td>
+
     <td>1.402</td>
 
     <td>21.46</td>
 
     <td>21.46</td>
 
</tr>
 
</tr>
<caption>Table 1. Summary table regarding to the debayer performance for several standard resolutions running at 30fps</caption>
+
<caption>Table 1. Performance for several standard resolutions at 30fps</caption>
 
</table>
 
</table>
 
</center>
 
</center>
Line 159: Line 180:
 
   <tr>
 
   <tr>
 
     <th>Resolution</th>
 
     <th>Resolution</th>
     <th>Maximum framerate (fps)</th>  
+
     <th>Maximum framerate (fps)*</th>  
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
Line 173: Line 194:
 
     <td>46</td>
 
     <td>46</td>
 
</tr>
 
</tr>
<caption>Table 2. Summary table for the maximum framerate using debayer algorithm for several standard resolutions</caption>
+
<caption>Table 2. Maximum framerate at standard resolutions</caption>
 
</table>
 
</table>
 
</center>
 
</center>
 
</html>
 
</html>
  
==CPU usage==
+
<br>
These measurements were taken with '''top''' app to see the behavior of the pipeline while running at 30fps, but we have to have in account that videotestsrc is used to generate the buffers and it consumes a lot of CPU.  
+
{{Ambox
 +
|type=notice
 +
|small=left
 +
|issue='''Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture.
 +
|style=width:unset;
 +
}}
 +
<br>
  
[[File:cpu-usage-debayer.png|frame|center|Cpu usage debayering for different resolutions at 30fps.]]
+
===CPU usage===
 +
These measurements were taken with the '''top''' app to monitor the behavior of the pipeline while running.
  
 +
[[File:cpu-usage-debayer.png|frame|center|CPU usage for '''debayer''' element]]
  
==Memory usage==
 
These measurements were taken with '''meminfo''' file to see the behavior of the pipeline while running at 30fps, but we have to have in account that videotestsrc is used to generate the buffers and it depends on the framerate due to the number of buffers generated by videotestsrc.
 
  
[[File:memory-debayer.png|frame|center|Memory usage debayering for different resolutions at 30fps.]]
+
===Memory usage===
 +
These measurements were taken with '''perf stat''' linux tool to measure the bandwidth needed by the pipeline.
  
 +
[[File:memory-debayer.png|frame|center|Memory bandwidth consumption by '''debayer''' element]]
  
==Execution time==
+
===Execution time===
These measurements were taken putting some '''timestamps''' before and after the processing to measure just the execution time for the debayer kernel algorithm by each frame and avoiding possible false measurements from the GStreamer plugin. The image below shows the debayer execution time by each frame for each resolution.
+
These measurements were taken using some '''timestamps''' before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.
  
[[File:exec-time-debayer.png|frame|center|Execution time debayering for different resolutions at 30fps.]]
+
[[File:exec-time-debayer.png|frame|center|Execution time for different resolutions with the '''debayer''' element]]
  
  
==Maximum Framerate==
+
===Maximum Framerate===
These measurements were taken with '''gstperf''' tool to see the behavior of the pipeline while running, with videotestsrc we are able to push buffers as much as possible to the element. The image below shows the maximum framerate that the debayer element supports. It depends on the execution time of the debayer kernel algorithm.
+
These measurements were taken with the '''gst-perf''' tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.  
  
 
The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.
 
The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.
Line 204: Line 233:
 
$ HEIGHT=1080
 
$ HEIGHT=1080
  
$ gst-launch-1.0 videotestsrc ! "video/x-raw,format=(string)RGBA,width=$WIDTH,height=$HEIGHT,framerate=(fraction)30/1" ! queue ! ispcldebayer ! fakesink -v
+
$ gst-launch-1.0 videotestsrc ! "video/x-bayer,format=bggr,width=$WIDTH,height=$HEIGHT,framerate=30/1" ! queue ! ispcldebayer ! perf ! fakesink -v
 +
 
 
</syntaxhighlight>
 
</syntaxhighlight>
  
[[File:max-framerate-debayer.png|frame|center|Maximum framerate debayering for different resolutions.]]
+
[[File:max-framerate-debayer.png|frame|center|Framerate for different resolutions with the '''debayer''' element]]
  
<noinclude>
+
== AWB Benchmarking ==
{{GStreamer Based Image Signal Processor/Foot|Performance/imx6|Performance/Color Space Conversion}}
 
</noinclude>
 
 
 
 
 
= AWB Benchmarking =
 
  
 
The following section describes some relevant performance measurements for the auto-white balance for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
 
The following section describes some relevant performance measurements for the auto-white balance for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
  
== Pipeline ==
+
=== Pipeline ===
  
 
All the measurements below were made using the following minimal pipeline.
 
All the measurements below were made using the following minimal pipeline.
Line 226: Line 251:
 
$ HEIGHT=1080
 
$ HEIGHT=1080
  
$ gst-launch-1.0 videotestsrc is-live=true ! "video/x-raw,format=(string)RGBA,width=$WIDTH,height=$HEIGHT,framerate=(fraction)30/1" ! queue ! ispclawb ! fakesink -v
+
$ gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-bayer,format=bggr,bpp=10,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispclbayer10to8 ! queue ! ispclawb ! fakesink -v
 
</syntaxhighlight>
 
</syntaxhighlight>
  
== Summary ==
+
=== Summary ===
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the auto-white balance algorithm.  
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the auto-white balance algorithm.  
 
<html>
 
<html>
Line 236: Line 261:
 
   <tr>
 
   <tr>
 
     <th>Resolution</th>
 
     <th>Resolution</th>
     <th>CPU usage (%) *</th>  
+
     <th>CPU usage (%)</th>  
     <th>Memory (kB) *</th>
+
     <th>Memory Bandwidth (GHz)</th>
 
     <th>Execution Time (ms)</th>
 
     <th>Execution Time (ms)</th>
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
 
     <td>640x480@30fps</td>
 
     <td>640x480@30fps</td>
     <td> </td>
+
     <td> 10 </td>
     <td> </td>
+
     <td> 0.994 </td>
     <td> </td>
+
     <td>3.11</td>
 
   </tr>
 
   </tr>
 
<tr>
 
<tr>
 
     <td>1280x720@30fps</td>
 
     <td>1280x720@30fps</td>
     <td> </td>
+
     <td> 12 </td>
     <td> </td>
+
     <td> 1.032 </td>
     <td> </td>
+
     <td>4.54</td>
 
</tr>
 
</tr>
 
<tr>
 
<tr>
 
     <td>1920x1080@30fps</td>
 
     <td>1920x1080@30fps</td>
     <td> </td>
+
     <td> 16 </td>
     <td> </td>
+
     <td> 1.239 </td>
     <td> </td>
+
     <td>8.52</td>
 
</tr>
 
</tr>
<caption>Table 1. Summary table regarding to the AWB performance for several standard resolutions running at 30fps</caption>
+
<caption>Table 1. Performance for several standard resolutions at 30fps</caption>
 
</table>
 
</table>
 
</center>
 
</center>
 
</html>
 
</html>
 
 
<span style="color:red"> '''Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture. </span>
 
  
  
Line 272: Line 294:
 
   <tr>
 
   <tr>
 
     <th>Resolution</th>
 
     <th>Resolution</th>
     <th>Maximum framerate (fps)</th>  
+
     <th>Maximum framerate (fps) *</th>  
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
 
     <td>640x480</td>
 
     <td>640x480</td>
     <td> </td>
+
     <td> 365 </td>
 
   </tr>
 
   </tr>
 
<tr>
 
<tr>
 
     <td>1280x720</td>
 
     <td>1280x720</td>
     <td> </td>
+
     <td> 135 </td>
 
</tr>
 
</tr>
 
<tr>
 
<tr>
 
     <td>1920x1080</td>
 
     <td>1920x1080</td>
     <td> </td>
+
     <td> 62 </td>
 
</tr>
 
</tr>
<caption>Table 2. Summary table for the maximum framerate using AWB algorithm for several standard resolutions</caption>
+
<caption>Table 2. Maximum framerate at standard resolutions</caption>
 
</table>
 
</table>
 
</center>
 
</center>
 
</html>
 
</html>
  
 +
<br>
 +
{{Ambox
 +
|type=notice
 +
|small=left
 +
|issue='''Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture.
 +
|style=width:unset;
 +
}}
 +
<br>
 +
 +
===CPU usage===
 +
These measurements were taken with the '''top''' app to monitor the behavior of the pipeline while running.
 +
 +
[[File:CPU usage for AWB.png|frame|center|CPU usage for '''AWB''' element]]
 +
 +
===Memory usage===
 +
These measurements were taken with '''perf stat''' linux tool to measure the bandwidth needed by the pipeline.
 +
 +
[[File:Memory Bandwidth for AWB.png|frame|center|Memory bandwidth consumption by '''AWB''' element]]
 +
 +
===Execution time===
 +
These measurements were taken using some '''timestamps''' before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.
 +
 +
[[File:Execution Time AWB.png|frame|center|Execution time for different resolutions with the '''AWB''' element]]
 +
 +
 +
===Maximum Framerate===
 +
These measurements were taken with the '''gst-perf''' tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.
 +
 +
The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.
 +
<syntaxhighlight lang=bash style="background-color: #f0fff0">
 +
$ WIDTH=1920
 +
$ HEIGHT=1080
 +
 +
$ gst-launch-1.0 videotestsrc ! "video/x-bayer,format=bggr,width=$WIDTH,height=$HEIGHT,framerate=30/1" ! queue ! ispclawb ! perf ! fakesink -v
 +
</syntaxhighlight>
  
= Histogram Equalization Benchmarking =
+
[[File:Maximum Framerate AWB.png|frame|center|Framerate for different resolutions with the '''AWB''' element]]
 +
 
 +
== Histogram Equalization Benchmarking ==
  
 
The following section describes some relevant performance measurements for the Histogram Equalization for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
 
The following section describes some relevant performance measurements for the Histogram Equalization for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.  
  
== Pipeline ==
+
=== Pipeline ===
  
 
All the measurements below were made using the following minimal pipeline.
 
All the measurements below were made using the following minimal pipeline.
Line 304: Line 363:
 
$ HEIGHT=1080
 
$ HEIGHT=1080
  
$ gst-launch-1.0 videotestsrc is-live=true ! "video/x-raw,format=(string)RGBA,width=$WIDTH,height=$HEIGHT,framerate=(fraction)30/1" ! queue ! ispcleq ! fakesink -v
+
$ gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-bayer,format=bggr,bpp=10,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispclbayer10to8 ! queue ! ispcleq ! fakesink -v
 
</syntaxhighlight>
 
</syntaxhighlight>
  
== Summary ==
+
=== Summary ===
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the Histogram Equalization algorithm.  
 
In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the Histogram Equalization algorithm.  
 
<html>
 
<html>
Line 314: Line 373:
 
   <tr>
 
   <tr>
 
     <th>Resolution</th>
 
     <th>Resolution</th>
     <th>CPU usage (%) *</th>  
+
     <th>CPU usage (%)</th>  
     <th>Memory (kB) *</th>
+
     <th>Memory Bandwidth (GHz)</th>
 
     <th>Execution Time (ms)</th>
 
     <th>Execution Time (ms)</th>
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
 
     <td>640x480@30fps</td>
 
     <td>640x480@30fps</td>
     <td> </td>
+
     <td> 10 </td>
     <td> </td>
+
     <td> 0.990 </td>
     <td> </td>
+
     <td>4.28</td>
 
   </tr>
 
   </tr>
 
<tr>
 
<tr>
 
     <td>1280x720@30fps</td>
 
     <td>1280x720@30fps</td>
     <td> </td>
+
     <td> 12 </td>
     <td> </td>
+
     <td> 1.047 </td>
     <td> </td>
+
     <td>6.07</td>
 
</tr>
 
</tr>
 
<tr>
 
<tr>
 
     <td>1920x1080@30fps</td>
 
     <td>1920x1080@30fps</td>
     <td> </td>
+
     <td> 16 </td>
     <td> </td>
+
     <td> 1.277 </td>
     <td> </td>
+
     <td>10.95</td>
 
</tr>
 
</tr>
<caption>Table 1. Summary table regarding to the Histogram Equalization performance for several standard resolutions running at 30fps</caption>
+
<caption>Table 1. Performance for several standard resolutions at 30fps</caption>
 
</table>
 
</table>
 
</center>
 
</center>
 
</html>
 
</html>
 
 
<span style="color:red"> '''Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture. </span>
 
  
  
Line 350: Line 406:
 
   <tr>
 
   <tr>
 
     <th>Resolution</th>
 
     <th>Resolution</th>
     <th>Maximum framerate (fps)</th>  
+
     <th>Maximum framerate (fps)*</th>  
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
 
     <td>640x480</td>
 
     <td>640x480</td>
     <td> </td>
+
     <td> 345 </td>
 
   </tr>
 
   </tr>
 
<tr>
 
<tr>
 
     <td>1280x720</td>
 
     <td>1280x720</td>
     <td> </td>
+
     <td> 135 </td>
 
</tr>
 
</tr>
 
<tr>
 
<tr>
 
     <td>1920x1080</td>
 
     <td>1920x1080</td>
     <td> </td>
+
     <td> 62 </td>
 
</tr>
 
</tr>
<caption>Table 2. Summary table for the maximum framerate using Histogram Equalization algorithm for several standard resolutions</caption>
+
<caption>Table 2. Maximum framerate at standard resolutions</caption>
 
</table>
 
</table>
 
</center>
 
</center>
 
</html>
 
</html>
 +
 +
<br>
 +
{{Ambox
 +
|type=notice
 +
|small=left
 +
|issue='''Note:''' take into consideration that these values were taken using the videotestsrc element, and may decrease with a camera source capture.
 +
|style=width:unset;
 +
}}
 +
<br>
 +
 +
===CPU usage===
 +
These measurements were taken with the '''top''' app to monitor the behavior of the pipeline while running.
 +
 +
[[File:CPU usage Eq.png|frame|center|CPU usage for '''Histogram Equalization''' element]]
 +
 +
===Memory usage===
 +
These measurements were taken with '''perf stat''' linux tool to measure the bandwidth needed by the pipeline.
 +
 +
[[File:Memory Bandwidth Eq.png|frame|center|Memory bandwidth consumption by '''Histogram Equalization''' element]]
 +
 +
===Execution time===
 +
These measurements were taken using some '''timestamps''' before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.
 +
 +
[[File:Execution Time Equalizer.png|frame|center|Execution time for different resolutions with the '''Histogram Equalization''' element]]
 +
 +
===Maximum Framerate===
 +
These measurements were taken with the '''gst-perf''' tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.
 +
 +
The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.
 +
<syntaxhighlight lang=bash style="background-color: #f0fff0">
 +
$ WIDTH=1920
 +
$ HEIGHT=1080
 +
 +
$ gst-launch-1.0 videotestsrc ! "video/x-bayer,format=bggr,width=$WIDTH,height=$HEIGHT,framerate=30/1" ! queue ! ispcleq ! perf ! fakesink -v
 +
 +
</syntaxhighlight>
 +
 +
[[File:Maximum Framerate Eq.png|frame|center|Framerate for different resolutions with the '''Histogram Equalization''' element]]
 +
 +
<noinclude>
 +
{{GStreamer Based Image Signal Processor/Foot|Performance/imx6|Troubleshoot}}
 +
</noinclude>

Latest revision as of 13:09, 22 July 2023


Previous: Performance/imx6 Index Next: Troubleshoot





Benchmark environment

The following setup was used for all the benchmarks:

GStreamer Bayer10 Support

GStreamer has support for 8-bit Bayer only. To enable 10-bit Bayer support, please, follow this wiki.

CSC Benchmarking

The following section describes some relevant performance measurements for the RGBA to NV12 color space conversion for a few standard resolutions. It begins with a summary of the results detailed in the following sections, as well as the pipelines used to capture such results.

Pipeline

All the measurements below were made using the following minimal pipeline.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 videotestsrc is-live=true ! "video/x-raw,format=(string)RGBA,width=$WIDTH,height=$HEIGHT,framerate=(fraction)30/1" ! queue ! ispclcsc ! fakesink -v

Summary

In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the CSC algorithm.

Resolution CPU usage (%) Memory Bandwidth (GHz) Execution Time (ms)
640x480@30fps 4 1.020 2.24
1280x720@30fps 10 1.034 6.19
1920x1080@30fps 14 1.466 13.17
Table 1. Performance for several standard resolutions at 30fps

Resolution Maximum framerate (fps) *
640x480 333
1280x720 120
1920x1080 55
Table 2. Maximum framerate at standard resolutions



CPU usage

These measurements were taken with the top app to monitor the behavior of the pipeline while running.

Error creating thumbnail: Unable to save thumbnail to destination
CPU usage for CSC element

Memory usage

These measurements were taken with perf stat Linux tool to measure the bandwidth needed by the pipeline.

Error creating thumbnail: Unable to save thumbnail to destination
Memory bandwidth consumption by CSC element

Execution time

These measurements were taken using some timestamps before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.

Error creating thumbnail: Unable to save thumbnail to destination
Execution time for different resolutions with the CSC element

Maximum Framerate

These measurements were taken with the gst-perf tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.

The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 videotestsrc ! "video/x-raw,format=(string)RGBA,width=$WIDTH,height=$HEIGHT,framerate=(fraction)30/1" ! queue ! ispclcsc ! fakesink -v
Error creating thumbnail: Unable to save thumbnail to destination
Framerate for different resolutions with the CSC element

Debayer Benckmarking

The following section describes some relevant performance measurements during debayering for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.

Pipeline

All the measurements below were made using the following minimal pipeline.

WIDTH=1920
HEIGHT=1080

$ gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-bayer,format=bggr,bpp=10,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispclbayer10to8 ! queue ! ispcldebayer ! fakesink -v

Summary

In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the debayer algorithm.

Resolution CPU usage (%) Memory Bandwidth (GHz) Execution Time (ms)
640x480@30fps 2 1.025 3.54
1280x720@30fps 2 1.084 9.89
1920x1080@30fps 3 1.402 21.46
Table 1. Performance for several standard resolutions at 30fps


Resolution Maximum framerate (fps)*
640x480 266
1280x720 101
1920x1080 46
Table 2. Maximum framerate at standard resolutions



CPU usage

These measurements were taken with the top app to monitor the behavior of the pipeline while running.

Error creating thumbnail: Unable to save thumbnail to destination
CPU usage for debayer element


Memory usage

These measurements were taken with perf stat linux tool to measure the bandwidth needed by the pipeline.

Error creating thumbnail: Unable to save thumbnail to destination
Memory bandwidth consumption by debayer element

Execution time

These measurements were taken using some timestamps before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.

Error creating thumbnail: Unable to save thumbnail to destination
Execution time for different resolutions with the debayer element


Maximum Framerate

These measurements were taken with the gst-perf tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.

The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 videotestsrc ! "video/x-bayer,format=bggr,width=$WIDTH,height=$HEIGHT,framerate=30/1" ! queue ! ispcldebayer ! perf ! fakesink -v
Error creating thumbnail: Unable to save thumbnail to destination
Framerate for different resolutions with the debayer element

AWB Benchmarking

The following section describes some relevant performance measurements for the auto-white balance for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.

Pipeline

All the measurements below were made using the following minimal pipeline.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-bayer,format=bggr,bpp=10,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispclbayer10to8 ! queue ! ispclawb ! fakesink -v

Summary

In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the auto-white balance algorithm.

Resolution CPU usage (%) Memory Bandwidth (GHz) Execution Time (ms)
640x480@30fps 10 0.994 3.11
1280x720@30fps 12 1.032 4.54
1920x1080@30fps 16 1.239 8.52
Table 1. Performance for several standard resolutions at 30fps


Resolution Maximum framerate (fps) *
640x480 365
1280x720 135
1920x1080 62
Table 2. Maximum framerate at standard resolutions



CPU usage

These measurements were taken with the top app to monitor the behavior of the pipeline while running.

Error creating thumbnail: Unable to save thumbnail to destination
CPU usage for AWB element

Memory usage

These measurements were taken with perf stat linux tool to measure the bandwidth needed by the pipeline.

Error creating thumbnail: Unable to save thumbnail to destination
Memory bandwidth consumption by AWB element

Execution time

These measurements were taken using some timestamps before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.

Error creating thumbnail: Unable to save thumbnail to destination
Execution time for different resolutions with the AWB element


Maximum Framerate

These measurements were taken with the gst-perf tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.

The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 videotestsrc ! "video/x-bayer,format=bggr,width=$WIDTH,height=$HEIGHT,framerate=30/1" ! queue ! ispclawb ! perf ! fakesink -v
Error creating thumbnail: Unable to save thumbnail to destination
Framerate for different resolutions with the AWB element

Histogram Equalization Benchmarking

The following section describes some relevant performance measurements for the Histogram Equalization for a few standard resolutions. It begins with a summary of the results detailed on the following sections, as well as the pipelines used to capture such results.

Pipeline

All the measurements below were made using the following minimal pipeline.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 v4l2src device=/dev/video0 ! video/x-bayer,format=bggr,bpp=10,width=$WIDTH,height=$HEIGHT,framerate=30/1 ! ispclbayer10to8 ! queue ! ispcleq ! fakesink -v

Summary

In this summary you can find measurements related with CPU usage, memory, execution time and maximum framerate supported by the Histogram Equalization algorithm.

Resolution CPU usage (%) Memory Bandwidth (GHz) Execution Time (ms)
640x480@30fps 10 0.990 4.28
1280x720@30fps 12 1.047 6.07
1920x1080@30fps 16 1.277 10.95
Table 1. Performance for several standard resolutions at 30fps


Resolution Maximum framerate (fps)*
640x480 345
1280x720 135
1920x1080 62
Table 2. Maximum framerate at standard resolutions



CPU usage

These measurements were taken with the top app to monitor the behavior of the pipeline while running.

Error creating thumbnail: Unable to save thumbnail to destination
CPU usage for Histogram Equalization element

Memory usage

These measurements were taken with perf stat linux tool to measure the bandwidth needed by the pipeline.

Error creating thumbnail: Unable to save thumbnail to destination
Memory bandwidth consumption by Histogram Equalization element

Execution time

These measurements were taken using some timestamps before and after the processing to measure just the execution time for the kernel algorithm on each frame and hence avoiding possible false measurements from the GStreamer plugin.

Error creating thumbnail: Unable to save thumbnail to destination
Execution time for different resolutions with the Histogram Equalization element

Maximum Framerate

These measurements were taken with the gst-perf tool to monitor the behavior of the pipeline while running. When using videotestsrc we are able to process as many buffers as the element can handle, hence the maximum value reported.

The following pipeline was used to test the maximum framerate, please note the use of videotestsrc.

$ WIDTH=1920
$ HEIGHT=1080

$ gst-launch-1.0 videotestsrc ! "video/x-bayer,format=bggr,width=$WIDTH,height=$HEIGHT,framerate=30/1" ! queue ! ispcleq ! perf ! fakesink -v
Error creating thumbnail: Unable to save thumbnail to destination
Framerate for different resolutions with the Histogram Equalization element


Previous: Performance/imx6 Index Next: Troubleshoot