Skip to content

TypeError: 'NoneType' object is not subscriptable #61

@Potracheno

Description

@Potracheno

python3 simple_example_v3.py

pygame 2.5.2 (SDL 2.28.2, Python 3.10.0)
Hello from the pygame community. https://www.pygame.org/contribute.html
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
I0000 00:00:1753013036.279139   32217 gl_context_egl.cc:85] Successfully initialized EGL. Major : 1 Minor: 5
I0000 00:00:1753013036.281840   32301 gl_context.cc:344] GL version: 3.2 (OpenGL ES 3.2 Mesa 24.2.8-1ubuntu1~24.10.1), renderer: Mesa Intel(R) UHD Graphics 630 (CFL GT2)
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
Traceback (most recent call last):
  File "/home/user/EyeGestures/examples/simple_example_v3.py", line 79, in <module>
    event, calibration = gestures.step(frame, calibrate, screen_width, screen_height, context="my_context")
  File "/home/user/miniconda3/envs/eye/lib/python3.10/site-packages/eyeGestures/__init__.py", line 142, in step
    key_points, blink, sub_frame = self.getLandmarks(frame)
  File "/home/user/miniconda3/envs/eye/lib/python3.10/site-packages/eyeGestures/__init__.py", line 65, in getLandmarks
    self.face.process(
  File "/home/user/miniconda3/envs/eye/lib/python3.10/site-packages/eyeGestures/face.py", line 81, in process
    self.landmarks = self._landmarks(self.face)
  File "/home/user/miniconda3/envs/eye/lib/python3.10/site-packages/eyeGestures/face.py", line 67, in _landmarks
    __complex_landmarks = __complex_landmark_points[0].landmark
TypeError: 'NoneType' object is not subscriptable

python3 troubleshooting_camera.py works

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions