Sports Biomechanics Analysis

Hi,

I recently purchased a Zed box and zed x camera.

The project I have in mind is recording a table tennis players movements, in order to analyse the execution of the different strokes from a biomechanics perspective.

In first tests I noticed that when doing body tracking while processing the image and trying to save it into an output video, the framerate I csn write st max is about 12fps when using 1080HD as input.

That fps is not enough for analyzing movements.

So my second approach is to decouple the camera grabbing from processing with threading.

The issue I am running into is that the receive_bodies method only seem to be able to work on the latest frame, not a frame I qeued to be processed.

Does anyone have an idea for me on how to continue?

Thanks,

Arno

Hi

The retrieve_bodies method is performing the skeleton detection and tracking on the last grabbed frame, ie the last call of the grab method.

The grabbing and processing of the skeleton detection can not be decoupled as you tried to.

Ok, but recording the svo file and then postprocessing should work, right? Would not be realtime, but it should not skip frames

Then, you don’t need to use threading at all. Calling grab(), then retrievebodies() in a loop will work.

The thing I don’t understand is why the low frame rate an issue if you are aiming for real time?

Stereolabs Support

I want to analyze movements, so I cannot afford to have low fps, as the gap between joint positions would be too big

Then, you need to increase the frame rate of the capture using the camera_fps Initparameter.

Stereolabs Support

Thats the thing, using 60fps and body tracking and videowriting leaves me at a 12-15fps for the recorded overlayed video

If you plan to record an SVO, running the body tracking module is unnecessary, as this data is not saved inside the SVO file.

Stereolabs Support

No, i was recording a normal mp4 with a cv videowriter, trying to output it in realtime. But as the realtime fps I can achieve is too low, I might have to go the way of svo recording and then processing