How to measure frame rate per second

Hi

I would like to know how to measure real frame per second in jetson

when i run my model in terminal i got the follwing message

jetsonnano3@jetsonnano3-desktop:~/remoteBuildTest/MATLAB_ws/R2019b/C/Users/Abdussalam/Desktop/Train_R-CNN_SmokeDetector10$ ./yolo2detectobject.elf
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected…
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 3264 x 2464 FR = 21.000000 fps Duration = 47619048 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: 3264 x 1848 FR = 28.000001 fps Duration = 35714284 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: 1920 x 1080 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: 1280 x 720 FR = 59.999999 fps Duration = 16666667 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: 1280 x 720 FR = 120.000005 fps Duration = 8333333 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: Running with following settings:
Camera index = 0
Camera mode = 4
Output Stream W = 1280 H = 720
seconds to Run = 0
Frame Rate = 120.000005
GST_ARGUS: PowerService: requested_clock_Hz=6048000
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.

Kindly i need step by step how to measure real frame per second while running the model ./yolo2detectobject.elf

Best,

Hi,
Not sure how ./yolo2detectobject.elf is implemented. If it is based on gstreamer, you can utilize fpsdisplaysink. An example is in
https://devtalk.nvidia.com/default/topic/1027772/jetson-tx2/two-csi-cameras-on-tx2/post/5227935/#5227935

Dear sir
Thanks for your reply

Yes i am using GStreamer

I tried this command

gst-launch-1.0 videotestsrc ! fpsdisplaysink

and i got 30 and drop is 0

so how can i implement this command while running the model as example

jetsonnano3@jetsonnano3-desktop:~/remoteBuildTest/MATLAB_ws/R2019b/C/Users/Abdussalam/Desktop/Train_R-CNN_SmokeDetector10$ ./yolo2detectobject.elf

Other question

when i run the model

i got this message

GST_ARGUS: Running with following settings:
Camera index = 0
Camera mode = 4
Output Stream W = 1280 H = 720
seconds to Run = 0
Frame Rate = 120.000005
GST_ARGUS: PowerService: requested_clock_Hz=6048000
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.

what does Frame Rate = 120.000005 mean

is it actual value or maximum value for width 1280 and Height 720

Best,

Dear sir,

Kindly if there is up[date for the above question

Best,

Hi,
You may check source code of yolo2detectobject.elf. If it is not based on gstreamer, you probably cannot leverage fpsdisplaysink.

For running Yolo models, we have samples in DeepStream SDK. You may also download it and try.

Dear sir,

Thanks for your reply

regarding to the question when i run the model

i got this message

GST_ARGUS: Running with following settings:
Camera index = 0
Camera mode = 4
Output Stream W = 1280 H = 720
seconds to Run = 0
Frame Rate = 120.000005
GST_ARGUS: PowerService: requested_clock_Hz=6048000
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.

what does Frame Rate = 120.000005 mean

is it actual value or maximum value for width 1280 and Height 720

Best,

Hi,
Please share where we can get source code of yolo2detectobject.elf. There are implementations from community and we probably miss this one. We would need to look at source code first and suggest next.

Dear sir,

Thanks for your consideration

find the link below here where you can find the elf file and matlab file for the code that i generated in jetson nano

https://gofile.io/?c=gf08Hm

other thing I used also this command in terminal

v4l2-ctl -d /dev/video0 --set-fmt-video=width=1280,height=720,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=100

and i was able to get real frame rate from the camera and i want to know how i use this command while i am running the yolo2detectobject.elf

Looking for your support

Best,

Hi,
You are probably using this:
https://www.mathworks.com/help/supportpkg/nvidia/ref/jetson.html
https://www.mathworks.com/hardware-support/nvidia-jetson.html

It is implemented by Matlab coder and you would need to contact Matlab for support. We don’t have source code of the implementation and not able to give suggestion.

Hi Danelll

I am looking when I run the file yolo2detectobject.elf in terminal which streaming the camera , so I want in the same time make the command

v4l2-ctl -d /dev/video0 --set-fmt-video=width=1280,height=720,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=100

in other terminal window for requesting how many frame per seconds

other way when I run the file yolo2detectobject.elf in terminal after finishing is there any log file that I can check to see if calculated the frame per second

Looking for your support

Best,

Hi,
Have you checked this:
https://www.mathworks.com/help/matlab/ref/profile.html
https://www.mathworks.com/help/matlab/matlab_prog/profiling-for-improving-performance.html

I don’t see APIs about frame rate profiling in this page. These look specific to Jetson platforms.
https://www.mathworks.com/help/supportpkg/nvidia/referencelist.html?type=function&category=deploy-to-nvidia-hardware

We don’t have experience in using Matlab, but it should be class-based. So profile functions should be valid for all Matlab applications. You may give it a try.