mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-30 13:10:47 +00:00
remove non-invasive recommendations from wall measures
This commit is contained in:
parent
0eb81b6e7c
commit
85b92bfecd
2 changed files with 10 additions and 6 deletions
|
|
@ -74,6 +74,9 @@ class Recommendations:
|
||||||
if self.property_instance.non_invasive_recommendations:
|
if self.property_instance.non_invasive_recommendations:
|
||||||
raise Exception("IMPLEMENT ME")
|
raise Exception("IMPLEMENT ME")
|
||||||
|
|
||||||
|
# Generally, inclusions is a global option and will overrule specific property non-invasive recommendations.
|
||||||
|
# This is done so that we can use inclusions to specify scenarios.
|
||||||
|
|
||||||
inclusions_full = [MEASURE_MAP[x] if x in MEASURE_MAP else x for x in self.inclusions]
|
inclusions_full = [MEASURE_MAP[x] if x in MEASURE_MAP else x for x in self.inclusions]
|
||||||
exclusions_full = [MEASURE_MAP[x] if x in MEASURE_MAP else x for x in self.exclusions]
|
exclusions_full = [MEASURE_MAP[x] if x in MEASURE_MAP else x for x in self.exclusions]
|
||||||
|
|
||||||
|
|
@ -99,7 +102,6 @@ class Recommendations:
|
||||||
|
|
||||||
property_recommendations = []
|
property_recommendations = []
|
||||||
phase = 0
|
phase = 0
|
||||||
# TODO: We should form measures form non-intrusive recommendations too
|
|
||||||
measures = self.find_included_measures()
|
measures = self.find_included_measures()
|
||||||
|
|
||||||
# Building Fabric
|
# Building Fabric
|
||||||
|
|
|
||||||
|
|
@ -163,7 +163,7 @@ class WallRecommendations(Definitions):
|
||||||
)
|
)
|
||||||
|
|
||||||
# Test filling cavity
|
# Test filling cavity
|
||||||
self.find_cavity_insulation(u_value, insulation_thickness, phase)
|
self.find_cavity_insulation(u_value, insulation_thickness, phase, measures)
|
||||||
|
|
||||||
return self.recommendations
|
return self.recommendations
|
||||||
|
|
||||||
|
|
@ -212,7 +212,7 @@ class WallRecommendations(Definitions):
|
||||||
or self.property.walls["is_filled_cavity"]
|
or self.property.walls["is_filled_cavity"]
|
||||||
) and (
|
) and (
|
||||||
"cavity_extract_and_refill"
|
"cavity_extract_and_refill"
|
||||||
not in self.property.non_invasive_recommendations
|
not in measures
|
||||||
):
|
):
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
@ -267,7 +267,7 @@ class WallRecommendations(Definitions):
|
||||||
if (is_cavity_wall and "cavity_wall_insulation" in measures) or "cavity_extract_and_refill" in measures:
|
if (is_cavity_wall and "cavity_wall_insulation" in measures) or "cavity_extract_and_refill" in measures:
|
||||||
if u_value >= self.BUILDING_REGULATIONS_PART_L_MAX_U_VALUE:
|
if u_value >= self.BUILDING_REGULATIONS_PART_L_MAX_U_VALUE:
|
||||||
# Test filling cavity
|
# Test filling cavity
|
||||||
self.find_cavity_insulation(u_value, insulation_thickness, phase)
|
self.find_cavity_insulation(u_value, insulation_thickness, phase, measures)
|
||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
@ -279,7 +279,7 @@ class WallRecommendations(Definitions):
|
||||||
# If the u-value is within regulations, we don't do anything
|
# If the u-value is within regulations, we don't do anything
|
||||||
return
|
return
|
||||||
|
|
||||||
def find_cavity_insulation(self, u_value, insulation_thickness, phase):
|
def find_cavity_insulation(self, u_value, insulation_thickness, phase, measures):
|
||||||
"""
|
"""
|
||||||
This method tests different materials to fill the cavity wall, determining which
|
This method tests different materials to fill the cavity wall, determining which
|
||||||
material will give us the best U-value.
|
material will give us the best U-value.
|
||||||
|
|
@ -299,6 +299,8 @@ class WallRecommendations(Definitions):
|
||||||
:param u_value: u_value of the starting wall
|
:param u_value: u_value of the starting wall
|
||||||
:param insulation_thickness: describes the insulation level of the wall. If "below average", we have a partially
|
:param insulation_thickness: describes the insulation level of the wall. If "below average", we have a partially
|
||||||
filled cavity wall
|
filled cavity wall
|
||||||
|
:param phase: The phase of the recommendation
|
||||||
|
:param measures: The measures we're considering
|
||||||
"""
|
"""
|
||||||
|
|
||||||
insulation_materials = pd.DataFrame(self.cavity_wall_insulation_materials)
|
insulation_materials = pd.DataFrame(self.cavity_wall_insulation_materials)
|
||||||
|
|
@ -333,7 +335,7 @@ class WallRecommendations(Definitions):
|
||||||
|
|
||||||
is_extraction_and_refill = (
|
is_extraction_and_refill = (
|
||||||
"cavity_extract_and_refill"
|
"cavity_extract_and_refill"
|
||||||
in self.property.non_invasive_recommendations
|
in measures
|
||||||
)
|
)
|
||||||
|
|
||||||
cost_result = self.costs.cavity_wall_insulation(
|
cost_result = self.costs.cavity_wall_insulation(
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue