overall quality improvement
This commit is contained in:
parent
7fb39171f4
commit
cf3f85c7f4
|
@ -122,8 +122,12 @@ class NrcanCatalog(Catalog):
|
|||
average_storey_height = archetype['average_storey_height']
|
||||
thermal_capacity = float(archetype['thermal_capacity']) * 1000
|
||||
extra_loses_due_to_thermal_bridges = archetype['extra_loses_due_thermal_bridges']
|
||||
infiltration_rate_for_ventilation_system_off = archetype['infiltration_rate_for_ventilation_system_off'] / cte.HOUR_TO_SECONDS
|
||||
infiltration_rate_for_ventilation_system_on = archetype['infiltration_rate_for_ventilation_system_on'] / cte.HOUR_TO_SECONDS
|
||||
infiltration_rate_for_ventilation_system_off = (
|
||||
archetype['infiltration_rate_for_ventilation_system_off'] / cte.HOUR_TO_SECONDS
|
||||
)
|
||||
infiltration_rate_for_ventilation_system_on = (
|
||||
archetype['infiltration_rate_for_ventilation_system_on'] / cte.HOUR_TO_SECONDS
|
||||
)
|
||||
|
||||
archetype_constructions = []
|
||||
for archetype_construction in archetype['constructions']:
|
||||
|
|
|
@ -48,7 +48,6 @@ class Fuel:
|
|||
"""
|
||||
if self._fixed_power is not None:
|
||||
return self._fixed_power/1000
|
||||
else:
|
||||
return None
|
||||
|
||||
@property
|
||||
|
|
|
@ -10,9 +10,9 @@ class DistributionSystem:
|
|||
"""
|
||||
Distribution system class
|
||||
"""
|
||||
|
||||
def __init__(self, system_id, name, system_type, supply_temperature, distribution_consumption_fix_flow,
|
||||
distribution_consumption_variable_flow, heat_losses):
|
||||
|
||||
self._system_id = system_id
|
||||
self._name = name
|
||||
self._type = system_type
|
||||
|
@ -80,7 +80,9 @@ class DistributionSystem:
|
|||
|
||||
def to_dictionary(self):
|
||||
"""Class content to dictionary"""
|
||||
content = {'Layer': {'id': self.id,
|
||||
content = {
|
||||
'Layer': {
|
||||
'id': self.id,
|
||||
'name': self.name,
|
||||
'type': self.type,
|
||||
'supply temperature [Celsius]': self.supply_temperature,
|
||||
|
|
|
@ -395,7 +395,9 @@ class Idf:
|
|||
def _add_occupancy(self, thermal_zone, zone_name):
|
||||
number_of_people = thermal_zone.occupancy.occupancy_density * thermal_zone.total_floor_area
|
||||
fraction_radiant = 0
|
||||
total_sensible = thermal_zone.occupancy.sensible_radiative_internal_gain + thermal_zone.occupancy.sensible_convective_internal_gain
|
||||
total_sensible = (
|
||||
thermal_zone.occupancy.sensible_radiative_internal_gain + thermal_zone.occupancy.sensible_convective_internal_gain
|
||||
)
|
||||
if total_sensible != 0:
|
||||
fraction_radiant = thermal_zone.occupancy.sensible_radiative_internal_gain / total_sensible
|
||||
|
||||
|
|
|
@ -33,15 +33,15 @@ class EilatPhysicsParameters:
|
|||
eilat_catalog = ConstructionCatalogFactory('eilat').catalog
|
||||
for building in city.buildings:
|
||||
if building.function not in Dictionaries().hub_function_to_eilat_construction_function.keys():
|
||||
logging.error(f'Building %s has an unknown building function %s', building.name, building.function)
|
||||
logging.error('Building %s has an unknown building function %s', building.name, building.function)
|
||||
continue
|
||||
function = Dictionaries().hub_function_to_eilat_construction_function[building.function]
|
||||
try:
|
||||
archetype = self._search_archetype(eilat_catalog, function, building.year_of_construction, self._climate_zone)
|
||||
|
||||
except KeyError:
|
||||
logging.error(f'Building %s has unknown construction archetype for building function: %s '
|
||||
f'[%s], building year of construction: %s and climate zone %s', building.name, function,
|
||||
logging.error('Building %s has unknown construction archetype for building function: %s '
|
||||
'[%s], building year of construction: %s and climate zone %s', building.name, function,
|
||||
building.function, building.year_of_construction, self._climate_zone)
|
||||
continue
|
||||
thermal_archetype = ThermalArchetype()
|
||||
|
|
|
@ -42,12 +42,7 @@ class ConstructionHelper:
|
|||
'Varennes': '6',
|
||||
'Laval': '6',
|
||||
'Longueuil': '6',
|
||||
'Saint-Leonard': '6',
|
||||
'': '6',
|
||||
'': '6',
|
||||
'': '6',
|
||||
'': '6',
|
||||
'': '6',
|
||||
'Saint-Leonard': '6'
|
||||
}
|
||||
|
||||
_reference_city_to_israel_climate_zone = {
|
||||
|
|
|
@ -40,8 +40,8 @@ class NrcanPhysicsParameters:
|
|||
archetype = self._search_archetype(nrcan_catalog, function, building.year_of_construction, self._climate_zone)
|
||||
|
||||
except KeyError:
|
||||
logging.error(f'Building %s has unknown construction archetype for building function: %s '
|
||||
f'[%s], building year of construction: %s and climate zone %s', building.name, function,
|
||||
logging.error('Building %s has unknown construction archetype for building function: %s '
|
||||
'[%s], building year of construction: %s and climate zone %s', building.name, function,
|
||||
building.function, building.year_of_construction, self._climate_zone)
|
||||
continue
|
||||
thermal_archetype = ThermalArchetype()
|
||||
|
|
|
@ -33,15 +33,15 @@ class NrelPhysicsParameters:
|
|||
nrel_catalog = ConstructionCatalogFactory('nrel').catalog
|
||||
for building in city.buildings:
|
||||
if building.function not in Dictionaries().hub_function_to_nrel_construction_function:
|
||||
logging.error(f'Building %s has unknown function %s', building.name, building.function)
|
||||
logging.error('Building %s has unknown function %s', building.name, building.function)
|
||||
continue
|
||||
function = Dictionaries().hub_function_to_nrel_construction_function[building.function]
|
||||
try:
|
||||
archetype = self._search_archetype(nrel_catalog, function, building.year_of_construction, self._climate_zone)
|
||||
except KeyError:
|
||||
logging.error(f'Building {building.name} has unknown construction archetype for building function: {function} '
|
||||
f'[{building.function}], building year of construction: {building.year_of_construction}'
|
||||
f' and climate zone {self._climate_zone}\n')
|
||||
logging.error('Building %s has unknown construction archetype for building function: %s '
|
||||
'[%s], building year of construction: %s and climate zone %s\n', building.name, function,
|
||||
building.function, building.year_of_construction, self._climate_zone)
|
||||
|
||||
continue
|
||||
thermal_archetype = ThermalArchetype()
|
||||
|
|
Loading…
Reference in New Issue
Block a user