demo.py doesn't work
manumaru opened this issue · comments
Hi, I tried to clone this project from here and run demo.py, but it stopped in the middle.
like this.
Does anyone know of a solution to this?
Palm detection blob : C:\ProgramData\Anaconda3\envs\DepthAI\hand_tracker\models\palm_detection_sh4.blob
Landmark blob : C:\ProgramData\Anaconda3\envs\DepthAI\hand_tracker\models\hand_landmark_lite_sh4.blob
Internal camera FPS set to: 23
Sensor resolution: (1920, 1080)
Internal camera image size: 1152 x 648 - crop_w:0 pad_h: 252
896 anchors have been created
Creating pipeline...
Creating Color Camera...
Creating Palm Detection Neural Network...
Creating Hand Landmark Neural Network (2 threads)...
Pipeline created.
Stack trace (most recent call last):
#31 Object "", at 00007FF8F7533693, in PyEval_GetFuncDesc
#30 Object "", at 00007FF8F7459315, in PyMethod_Self
#29 Object "", at 00007FF8F7455FA6, in PyObject_MakeTpCall
#28 Object "", at 00007FF8F7456FE0, in PyMethodDef_RawFastCallKeywords
#27 Object "", at 00007FF8CF419F72, in pybind11::error_already_set::error_already_set
#26 Object "", at 00007FF8CF43D09C, in PyInit_depthai
#25 Object "", at 00007FF8CF592A92, in PyInit_depthai
#24 Object "", at 00007FF8CF58CF4D, in PyInit_depthai
#23 Object "", at 00007FF8CF568643, in PyInit_depthai
#22 Object "", at 00007FF8CF576EA1, in PyInit_depthai
#21 Object "", at 00007FF8CF5768EA, in PyInit_depthai
#20 Object "", at 00007FF8CF5D9A9D, in PyInit_depthai
#19 Object "", at 00007FF8CF64002C, in PyInit_depthai
#18 Object "", at 00007FF97C4B478C, in RaiseException
#17 Object "", at 00007FF97ED52CD3, in RtlRaiseException
#16 Object "", at 00007FF97ED55A0A, in RtlRestoreContext
#15 Object "", at 00007FF97EDC82FF, in _chkstk
#14 Object "", at 00007FF8CF63DF4C, in PyInit_depthai
#13 Object "", at 00007FF8CF63F385, in PyInit_depthai
#12 Object "", at 00007FF8CF643008, in PyInit_depthai
#11 Object "", at 00007FF8CF642263, in PyInit_depthai
#10 Object "", at 00007FF8CF6419F9, in PyInit_depthai
#9 Object "", at 00007FF8CF63EF96, in PyInit_depthai
#8 Object "", at 00007FF97ED589D3, in RtlUnwindEx
#7 Object "", at 00007FF97EDC837F, in _chkstk
#6 Object "", at 00007FF8CF63DF4C, in PyInit_depthai
#5 Object "", at 00007FF8CF63F385, in PyInit_depthai
#4 Object "", at 00007FF8CF642F35, in PyInit_depthai
#3 Object "", at 00007FF8CF63E9E9, in PyInit_depthai
#2 Object "", at 00007FF8CF643C07, in PyInit_depthai
#1 Object "", at 00007FF8CF64C27A, in PyInit_depthai
#0 Object "", at 00007FF8CF575784, in PyInit_depthai
Environment:
depthai 2.13.3.0
depthai-sdk 1.1.6
opencv-contrib-python 4.5.1.48
opencv-python 4.5.1.48
Windows11 64bit
Thanks.
Hi,
It is the first time I see this kind of message. I don't have windows 11 and cannot try to reproduce. Do you get the same error when running other dephai scripts ?
Thanks for the reply.
I have touched some of the example cases on this site
, but so far I have only seen the similar error in "Pose Estimation" and "Hand Tracking".
However, Pose Estimation also stops with a slightly different error.
Like this.
(OAKDLite) C:\ProgramData\Anaconda3\envs\DepthAI\depthai_blazepose>python demo.py Pose detection blob file : C:\ProgramData\Anaconda3\envs\DepthAI\depthai_blazepose\models\pose_detection_sh4.blob Landmarks using blob file : C:\ProgramData\Anaconda3\envs\DepthAI\depthai_blazepose\models\pose_landmark_full_sh4.blob Internal camera FPS set to: 13 Sensor resolution: (1920, 1080) Internal camera image size: 1152 x 648 - crop_w:0 pad_h: 252 2254 anchors have been created Creating pipeline... Creating Color Camera... Creating Pose Detection pre processing image manip... Creating Pose Detection Neural Network... Creating Landmark Neural Network... Pipeline created. Stack trace (most recent call last): #14 Object "", at 00007FF97CD254E0, in BaseThreadInitThunk #13 Object "", at 00007FF8C9960DE8, in PyInit_depthai #12 Object "", at 00007FF8C987232C, in PyInit_depthai #11 Object "", at 00007FF8C98E9C07, in PyInit_depthai #10 Object "", at 00007FF8C995002C, in PyInit_depthai #9 Object "", at 00007FF97C4B478C, in RaiseException #8 Object "", at 00007FF97ED52CD3, in RtlRaiseException #7 Object "", at 00007FF97ED55A0A, in RtlRestoreContext #6 Object "", at 00007FF97EDC82FF, in _chkstk #5 Object "", at 00007FF8C994DF4C, in PyInit_depthai #4 Object "", at 00007FF8C994F385, in PyInit_depthai #3 Object "", at 00007FF8C9953008, in PyInit_depthai #2 Object "", at 00007FF8C99523D0, in PyInit_depthai #1 Object "", at 00007FF8C9960B47, in PyInit_depthai #0 Object "", at 00007FF8C99608C8, in PyInit_depthai
The Python version is 3.8.12, and the following are all the libraries installed.
argcomplete 1.12.1 argon2-cffi 21.3.0 argon2-cffi-bindings 21.2.0 attrs 21.4.0 backcall 0.2.0 bleach 4.1.0 blobconverter 1.2.8 boto3 1.17.39 botocore 1.20.112 certifi 2021.10.8 cffi 1.15.0 charset-normalizer 2.0.9 colorama 0.4.4 cryptography 36.0.1 cycler 0.11.0 debugpy 1.5.1 decorator 5.1.0 defusedxml 0.7.1 Deprecated 1.2.13 depthai 2.13.3.0 depthai-sdk 1.1.6 c:\programdata\anaconda3\envs\depthai\depthai_sdk\src entrypoints 0.3 ffmpy3 0.2.4 fonttools 4.28.5 gcloud 0.18.3 googleapis-common-protos 1.54.0 httplib2 0.20.2 idna 3.3 importlib-resources 5.4.0 imutils 0.5.4 ipykernel 6.6.1 ipython 7.30.1 ipython-genutils 0.2.0 ipywidgets 7.6.5 jedi 0.18.1 Jinja2 3.0.3 jmespath 0.10.0 jsonschema 4.3.3 jupyter-client 7.1.0 jupyter-core 4.9.1 jupyterlab-pygments 0.1.2 jupyterlab-widgets 1.0.2 jwcrypto 1.0 kiwisolver 1.3.2 MarkupSafe 2.0.1 matplotlib 3.5.1 matplotlib-inline 0.1.3 mistune 0.8.4 nbclient 0.5.9 nbconvert 6.4.0 nbformat 5.1.3 nest-asyncio 1.5.4 notebook 6.4.6 numpy 1.22.0 oauth2client 4.1.3 open3d 0.10.0.0 opencv-contrib-python 4.5.1.48 opencv-python 4.5.1.48 packaging 21.3 pandocfilters 1.5.0 parso 0.8.3 pickleshare 0.7.5 Pillow 9.0.0 pip 21.3.1 prometheus-client 0.12.0 prompt-toolkit 3.0.24 protobuf 3.19.1 pyasn1 0.4.8 pyasn1-modules 0.2.8 pycparser 2.21 pycryptodome 3.12.0 Pygments 2.11.1 pyparsing 3.0.6 PyQt5 5.15.5 PyQt5-Qt5 5.15.2 PyQt5-sip 12.9.0 Pyrebase4 4.5.0 pyrsistent 0.18.0 python-dateutil 2.8.2 python-jwt 3.3.2 pytube 11.0.2 pyusb 1.2.1 pywin32 303 pywinpty 1.1.6 PyYAML 6.0 pyzmq 22.3.0 requests 2.26.0 requests-toolbelt 0.9.1 rsa 4.8 s3transfer 0.3.7 Send2Trash 1.8.0 sentry-sdk 1.5.1 setuptools 58.0.4 six 1.16.0 terminado 0.12.1 testpath 0.5.0 tornado 6.1 traitlets 5.1.1 urllib3 1.26.7 wcwidth 0.2.5 webencodings 0.5.1 wheel 0.37.0 widgetsnbextension 3.5.2 wincertstore 0.2 wrapt 1.13.3 zipp 3.7.0
pybind11::error_already_set::error_already_set
I have looked into the error here, but was not sure about it.
I feel it's a bit unlikely that Windows 11 is the cause, but do you have any other ideas?
The device I'm using is an OAK-D-lite.
In your log, we see "Pipeline created" but don't see ""Pipeline started - USB speed:", so the problem happens either in
depthai_hand_tracker/HandTracker.py
Line 216 in c803ad3
depthai_hand_tracker/HandTracker.py
Line 217 in c803ad3
To be sure that the problem does not come from line 216, can you comment or remove the 2 lines 216 and 218 (let 217 as it is). These 2 lines are not necessary later on.
Also, please update depthai to the latest version (2.14.1).
The code of Pose Estimation is very similar to Hand Tracking, so the problem is likely similar.
Do you know the Luxonis Community discord ? https://discord.com/invite/4hGT3AFPMZ
I ask, because if the problem is still present with the latest depthai lib, I think the best option to get help will be to post your issue on the #windows channel.
Thank you for quickly replying.
I tried commenting out lines 216 and 218, and now it goes out to Pipeline created and finishes running Python.
attached image)
I also updated depthai from 2.13.3.0 to 2.14.1.0 and it no longer freezes but still ends up running Python.(Return to input acceptance status)
Thank you also for introducing the Luxonis Community on Discord.
I didn't know about it, so I'm going to register now and ask about it here!
Thank u so much!!
I changed the USB cable and it fixed the problem.OMG!
Thank you for your help, geaxgx!!