Comments (10)
I'm having the same problem.
When a sensor becomes unavailable, the average value is wrong, considering the value as 0 instead of ignoring it
from ha-average.
Came here to report this; I now have millions of logs from this component because it can't find the average for an unknown or unavailable entity id.
from ha-average.
Hi. Even though in the documentation is stated that: "By default, undefined values are not included in the average calculation" upon HA core restart i get low and zero values:
I believe this happens because the availability of the sensors. It also causes issues with other entities that use the average sensor as input:
from ha-average.
For me it seems that this started when I updated HA from 2021.12.2 to 2021.12.8. At least for me this hasn't happened before that upgrade. Upgraded Average to 2.2.1 didn't help.
- platform: average
name: 'Average Temperature House'
unique_id: __legacy__
duration:
minutes: 30
entities:
- sensor.kitchen_ble_temperature
- sensor.guestroom_ble_temperature
- sensor.livingroom_ble_temperature
- sensor.xiaomi_temp_childrensroom_temperature
As you can see from the picture all entities are between 20.9 and 22.6, and still average is 16.26. One of those sensors is offline since 10:10. But that big drop happened at 11:05.
I would assume that one sensor would be ruled out as it has happened before. Could you please check into this?
Edit:
Added second average to verify my findings. Second average is with same setup but without livingroom_ble_temperature sensor. All other details are same, except this one calculates average without that one failed sensor. This one calculates average correctly. So ruling out bad sensors doesn't work as it supposed to.
from ha-average.
Any update on this one? I'm currently using built-in mean calculation instead of this, because it can handle missing values just fine. But it obviously isn't as versatile as this. And it doesn't calculate average during some time period. That's why I would like to use this component instead.
from ha-average.
I think the restart related part of this issue is related to #98. Though I wasn't able to figure out the root cause.
from ha-average.
Same here, I see problem still open
from ha-average.
I switched to the native HA average sensor in the helpers page. It is behaving as supposed
from ha-average.
Though the built-in HA integrations behave differently, eg. they go unavailable immediately after the sensor goes unavailable (eg. WiFi outage), and generic_thermostat will not change state on unavailable temperature.
In my case I've added a wrapper sensor to get a default value for the thermostat, and I use the built-in filter (average) integration sensor to draw graphs (without the jumps to the default temperature). See: https://community.home-assistant.io/t/average-sensor/111674/154
from ha-average.
Same issue here, an undefined value drops the average.
from ha-average.
Related Issues (20)
- Average Sensor is Unavailable due to Get_Instance error in log. HOT 5
- Possible Service Call To Reset An Average? HOT 1
- Configuration items HOT 1
- Add Interval Option HOT 3
- Data from the current month only HOT 1
- Looks like HA 2022.10 is breaking this component again HOT 1
- Fix hasn't worked: Average sensor still records lot of unnecessary attribute in the recorder that fills up the database quite fast HOT 1
- Issue in 2022.10.x Temperature HOT 4
- Shut be updated!? HOT 4
- Multiple Entity calculation timeout
- Sensor fails if temperature unit is "f" vs "F" HOT 1
- How to avoid error on HA Startup when entity is not available? HOT 1
- convert_temperature issue/error HOT 5
- Set interval using GUI
- Posibility restrict use only last value from dedicated scanning period.
- Problem with propagation of temperature unit when averaging a statistics helper
- Frequency of sensor update HOT 3
- Hi, the integration seems to break in HA 23.3.1 HOT 11
- This integration will stop working with Home Assistant 2023.4 HOT 8
- can't get average temperature over a 1 day period of last week HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ha-average.