Pyds.user_copyfunc and user_releasefunc caused bad_function_call

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU) P4
• DeepStream Version 5.1
• JetPack Version (valid for Jetson only)
• TensorRT Version7
• NVIDIA GPU Driver Version (valid for GPU only) 11.1
• Issue Type( questions, new requirements, bugs)
• How to reproduce the issue ? (This is for bugs. Including which sample app is using, the configuration files content, the command line used and other details for reproducing)
• Requirement details( This is for new requirement. Including the module name-for which plugin or for which sample application, the function description)

Inside docker:
docker run -it --rm --gpus all -v /root/data/workspace/python:/opt/nvidia/deepstream/deepstream-5.1/sources/python nvcr.io/nvidia/deepstream:5.1-21.02-triton-updated-03

Running test similar to Test4, but always get error
Frame Number = 26 Vehicle Count = 2 Person Count = 1
Frame Number = 27 Vehicle Count = 2 Person Count = 1
Frame Number = 28 Vehicle Count = 2 Person Count = 1
Frame Number = 29 Vehicle Count = 2 Person Count = 1
Frame Number = 30 Vehicle Count = 2 Person Count = 1
Frame Number = 31 Vehicle Count = 2 Person Count = 1
terminate called after throwing an instance of ‘std::bad_function_call’
what(): bad_function_call

I managed to narrow down the cause as the title suggest, when I comment below 2 lines of code, it works well.
pyds.user_copyfunc(user_event_meta, meta_copy_func)
pyds.user_releasefunc(user_event_meta, meta_free_func)

cfg_amqp.txt (1.3 KB)
deepstream_test_0.py (29.3 KB)
dstest1_pgie_config.txt (3.4 KB)
msgconv_config.txt (1.9 KB)
test_0_tracker_config.txt (1.8 KB)
tracker_config.yml (6.5 KB)

Silly, just figured that I forgot to register the call backs.

#registering callbacks
pyds.register_user_copyfunc(meta_copy_func)
pyds.register_user_releasefunc(meta_free_func)

Glad to know issue fixed, thanks for the update.