Finalize the class comments and descriptions
This commit is contained in:
parent
ed2ae3e9b6
commit
0321072c0e
@ -46,6 +46,10 @@ class LCACarbonWorkflow:
|
||||
building_envelope_end_of_life_emission: <class 'float'>
|
||||
building_opening_end_of_life_emission: <class 'float'>
|
||||
building_component_end_of_life_emission: <class 'float'>
|
||||
|
||||
The above attributes will be computed when the calculate_emission()
|
||||
method of a LCACarbonWorkflow object is called.
|
||||
|
||||
:param city_path: Either a path to the buildings (GeoJson)
|
||||
file or the content of such a file.
|
||||
:param archetypes_catalog_file_name: Path to the buildings'
|
||||
@ -91,6 +95,26 @@ class LCACarbonWorkflow:
|
||||
self.building_component_end_of_life_emission = []
|
||||
|
||||
def calculate_building_component_emission(self, building):
|
||||
"""
|
||||
This method is the core of the whole class. It takes each building
|
||||
contained in the city object and calculates and returns the envelope
|
||||
and opening emission of the embodied and end of life cycles. The building
|
||||
comes from the calculate_emission() method which goes through every
|
||||
building of the city object (meaning the input of the LCACarbonWorkflow
|
||||
object.
|
||||
The calculate_building_component_emission() method goes through each
|
||||
surface of the given building then each boundary of that surface to
|
||||
calculate the embodied and end of life emission of openings and the
|
||||
envelope of the building. It is being carried out by utilizing to
|
||||
hidden methods of the current class (methods contain description.)
|
||||
At the end, a tuple will be returned, containing the emissions
|
||||
attributes. The tuple will be unpacked in the calculate_emission()
|
||||
method. The attributes and their types are explained in the constructor.
|
||||
The building parameter comes from the calculate_emission() method
|
||||
which iterates through the city object buildings.
|
||||
:param building: <class 'hub.city_model_structure.building.Building'>
|
||||
:return: <class 'tuple'>
|
||||
"""
|
||||
surface_envelope_emission = []
|
||||
surface_opening_emission = []
|
||||
surface_envelope_end_of_life_emission = []
|
||||
@ -149,6 +173,8 @@ class LCACarbonWorkflow:
|
||||
calculate_building_component_emission() method. The output also is used
|
||||
in the calculate_building_component_emission() method. So the current
|
||||
method is hidden to the user.
|
||||
The method utilizes the EnvelopeEmission and EndOfLifeEmission classes of
|
||||
(currently named) life_cycle_assessment series of class.
|
||||
:param boundary: <class
|
||||
'hub.city_model_structure.
|
||||
building_demand.thermal_boundary.ThermalBoundary'>
|
||||
@ -192,6 +218,8 @@ class LCACarbonWorkflow:
|
||||
Window's thickness assumed the same as wall's thickness
|
||||
These two values are being used to calculate window's workload for
|
||||
the End of Life emission evaluation.
|
||||
The method utilizes the OpeningEmission and EndOfLifeEmission classes of
|
||||
(currently named) life_cycle_assessment series of class.
|
||||
:param building: <class 'hub.city_model_structure.building.Building'>
|
||||
:param surface: <class
|
||||
'hub.city_model_structure.building_demand.surface.Surface'>
|
||||
|
Loading…
Reference in New Issue
Block a user