moondream
moondream copied to clipboard
use gaze detect only detecting faces don't have their gaze directions
gaze_result = model.detect_gaze(pil_image, face_center) gaze_result:{'gaze': None}
Currently it only returns gaze if it thinks the gaze point is within the image. There's a setting you can use to change that behavior: https://github.com/vikhyat/moondream/blob/main/moondream/torch/moondream.py#L541-L546
Considering changing it to always return the predicted gaze by default and have a separate boolean output indicating whether it's out of frame or not; that way folks who are interested in direction can still use it easily.