feat(perception): geometric face emotion classifier (Issue #359) #361
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "sl-perception/issue-359-face-emotion"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #359
Summary
mouth_open,smile(lip-corner elevation),brow_raise,brow_furl,eye_open— all relative to face heightFaceEmotionArrayto/saltybot/face_emotionsat ≤15 fpsClassification rules (priority order)
Test plan
python3 -m pytest test/test_face_emotion.py -v— 48/48 passed🤖 Generated with Claude Code
Classifies facial expressions into neutral/happy/surprised/angry/sad using geometric rules over MediaPipe Face Mesh landmarks — no ML model required at runtime. Rules ----- surprised: brow_raise > 0.12 AND eye_open > 0.07 AND mouth_open > 0.07 happy: smile > 0.025 (lip corners above lip midpoint) angry: brow_furl > 0.02 AND smile < 0.01 sad: smile < -0.025 AND brow_furl < 0.015 neutral: default Changes ------- - saltybot_scene_msgs/msg/FaceEmotion.msg — per-face emotion + features - saltybot_scene_msgs/msg/FaceEmotionArray.msg - saltybot_scene_msgs/CMakeLists.txt — register new msgs - _face_emotion.py — pure-Python: FaceLandmarks, compute_features, classify_emotion, detect_emotion, from_mediapipe - face_emotion_node.py — subscribes /camera/color/image_raw, publishes /saltybot/face_emotions (≤15 fps) - test/test_face_emotion.py — 48 tests, all passing - setup.py — add face_emotion entry point Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>