robmarkcole / HASS-Deepstack-object

Home Assistant custom component for using Deepstack object detection
https://community.home-assistant.io/t/face-and-person-detection-with-deepstack-local-and-free/92041
MIT License
439 stars 98 forks source link

Add last_detection attribute? #30

Closed robmarkcole closed 5 years ago

robmarkcole commented 5 years ago

Add attribute to display the time of the last detection of an object? Alternatively we could place the timestamp in the processed image.

jaburges commented 5 years ago

this would be helpful for things like cars - where motion is detected (say a tree moves in the wind), and there is a car in the driveway. Simple car > 0 logic would fire alerts all the time. However car new > car old would be useful, so only alerts if a new car is detected.

robmarkcole commented 5 years ago

@jaburges deepstack cannot identify specific cars unfortunately

jaburges commented 5 years ago

no, but it can detect an increase in the number of cars compared to last value. So car on driveway = 1 (so car.old = 1) new car is detected alert is triggered as car.new > car.old

This would also prevent alerts constantly due to the "I see a car" when its been there the whole time.

robmarkcole commented 5 years ago

I don't know what you mean, the state of the sensor is the number of target objects identified. You also have the event image_processing.object_detected which is fired for each object detected.

robmarkcole commented 5 years ago

This would be a nice idea for tracking recognised faces, but maybe should be on the person integration

robmarkcole commented 5 years ago

Added in https://github.com/robmarkcole/HASS-Deepstack-object/pull/59