robmarkcole / HASS-Sighthound

Beta features for Home Assistant Sighthound integration
https://www.home-assistant.io/integrations/sighthound/
MIT License
34 stars 10 forks source link

Graph Vehicle Statistics #26

Open stephenmetts opened 3 years ago

stephenmetts commented 3 years ago

Firstly, thank you for an awesome add to Home Assistant. I've been playing with this, and thoroughly enjoy it. I have a suggestion for an improvement. As someone who has high traffic in front of their house, it would be interesting to see statistics on vehicles that pass by. For example, right now in my events I can see the following data:

{"entity_id": "image_processing.sighthound_garage_2", "plate": "JDJ7182", "vehicle_type": "car", "make": "Mercedes-Benz", "model": "CLS-Class", "color": "black", "region": "Mississippi", "bounding_box": [0.13503, 0.20703, 0.47454, 0.47266]}

It would be great to gather statistics on how many Ford, Mercedes-Benz, etc... the system recognizes over time. The same for color, region, model, etc...

At this time, the only method I can identify is a database query.

robmarkcole commented 3 years ago

Database query is what I recommend, unless you can propose an alternative? You could create a SQL sensor to return the metrics you want

band8266 commented 3 years ago

How about adding the saved file-path for the processed image in the event data, so that one could also query the image?

robmarkcole commented 3 years ago

Honestly I just dont have free time for much open source work these days, so new features will require a PR