Solved: i found this forum here:
and use these commands to uninstall the pyds and install them again using these commands here:
cd /opt/nvidia/deepstream/deepstream
./user_additional_install.sh
./user_deepstream_python_apps_install.sh -v 1.2.0 #(version according to deepstream)
before founding these i used to install them using this github rep here:
so reinstalling the pyds resolved the issue here and now everything working perfectly.
i appreciate you help here.
Thank you @fanzh