mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
hot water working nicely
This commit is contained in:
parent
aa084a20df
commit
4967ea1e66
2 changed files with 9 additions and 1 deletions
|
|
@ -58,7 +58,7 @@ def handler():
|
|||
df = df.reset_index(drop=True)
|
||||
|
||||
import numpy as np
|
||||
idx = 27
|
||||
idx = 1
|
||||
record = df[df.index == idx].to_dict("records")[0]
|
||||
record = {k: v for k, v in record.items() if v not in [None, np.nan]}
|
||||
from pprint import pprint
|
||||
|
|
|
|||
|
|
@ -70,6 +70,11 @@ class HotWaterAttributes:
|
|||
'circulator', # A pump used to circulate hot water in the system
|
||||
]
|
||||
|
||||
# Indicate if the information is assumed
|
||||
ASSUMED = [
|
||||
'assumed'
|
||||
]
|
||||
|
||||
def __init__(self, description: str):
|
||||
self.description: str = clean_description(description.lower())
|
||||
|
||||
|
|
@ -106,4 +111,7 @@ class HotWaterAttributes:
|
|||
"no_system_present": find_keyword(self.description, self.NO_SYSTEM_PRESENT_KEYWORDS),
|
||||
}
|
||||
|
||||
assumed_found = find_keyword(self.description, self.ASSUMED)
|
||||
result["assumed"] = True if assumed_found else False
|
||||
|
||||
return result
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue