UE5 Crash In the RetrieveBodies function

Hi i’m creating interactive project with bodytracking
Everything was fine, but sometimes I get crash error
This error occurs randomly
I upgraded my sdk from 4.0.3 to 4.0.5, but it was the same

UE Crash Log :

sl_zed64
sl_zed64
sl_zed_c
sl_zed_c
ZEDSamples_Win64_Shipping!USlCameraProxy::RetrieveBodies() [G:\Project\2023\Chuncheon\zed-UE5-main\Plugins\Stereolabs\Source\Stereolabs\Private\Core\StereolabsCameraProxy.cpp:1508]
ZEDSamples_Win64_Shipping!<lambda_29381b110c09b0d66b6ae940fe3b7806>::operator()() [G:\Project\2023\Chuncheon\zed-UE5-main\Plugins\Stereolabs\Source\Stereolabs\Private\Threading\StereolabsAIDetectionRunnable.cpp:121]
ZEDSamples_Win64_Shipping!TBaseFunctorDelegateInstance<void __cdecl(enum ESlErrorCode,FSlTimestamp const &),FDefaultDelegateUserPolicy,TFunction<void __cdecl(enum ESlErrorCode,FSlTimestamp const &)> >::ExecuteIfSafe() [C:\Program Files\Epic Games\UE_5.1\Engine\Source\Runtime\Core\Public\Delegates\DelegateInstancesImpl.h:848]
ZEDSamples_Win64_Shipping!USlCameraProxy::Grab() [G:\Project\2023\Chuncheon\zed-UE5-main\Plugins\Stereolabs\Source\Stereolabs\Private\Core\StereolabsCameraProxy.cpp:796]
ZEDSamples_Win64_Shipping!FSlGrabRunnable::Run() [G:\Project\2023\Chuncheon\zed-UE5-main\Plugins\Stereolabs\Source\Stereolabs\Private\Threading\StereolabsGrabRunnable.cpp:24]
ZEDSamples_Win64_Shipping!FRunnableThreadWin::Run()

crash dmp file debug :





I’m using a modified BP_BodyTracking_Visualizer in the sample

System -
Camera : ZED2
UE Version : 5.1.1
OS : Windows 10 (22H2)
CPU : AMD Ryzen 9 5950X 16-Core Processor
GPU: NVIDIA GeForce RTX 3080
Cuda : 12.1.1_531.14
SDK : 4.0.3 And 4.0.5

I ran windbg and checked, but it seems that opencv is getting an error

Then, I think there is an error by delivering a null value from Unreal to Opencv
Camera ID is 0 fixed, sl_bodies is a variable that takes a value from cv, and if the last variable is 0 fixed, all that remains is BodyTrackingRuntimeParameters, but I’m a little confused if this value can be null…
or maybe just a opencv problem?

Hi @satasam, welcome to the forums!

Thanks for the detailed report and analysis, we will investigate this.
I’d like to ask a bit more information on the context of the crash(es, it seems):

  • What depth mode where you using?
  • With which body models did the crash happen? 34, 38, both?
  • Any other details that could help reproduce it? To be fair, your report was quite exhaustive already.

Hi, thank you for replying!

Depth mode uses Ultra,
The body model uses 34

And another values are
DepthMaximumDistance and MaxRange at BodyTrackingParameters are 400
Set as static is true,
Detection model is Human body accurate
Minimum Keypoints Threshold at BodyTrackingRuntimeParameters is 6

Except for these, the value is the same as the sample

Our game is use both hands to grab a falling object or
creates a wind and blows away the object

I used keypoint 2d to locate the hand and use it for interaction

bg

This is the camera view ,set it low for the children

I hope this information is helpful
Thank you

Hi @satasam,

What version of DirectX are you using? If possible, can you try using Dx11 if you were on Dx12?
We’ve had some reports similar to yours, solved by going back to Dx11, while we’re looking for the exact cause.

Hi, sorry for the late reply

Unfortunately, I was already using Direct11 for other reasons
And I think we’ve found a solution
After changing the body format from 34 to 38 in body tracking parameters,
no error occurred for more than 10 days

Maybe this was the cause of the error?
Anyway, thank you so much for your help!

1 Like