dragonfly_energy.properties.building module

Building Energy Properties.

class dragonfly_energy.properties.building.BuildingEnergyProperties(host, construction_set=None)[source]

Bases: object

Energy Properties for Dragonfly Building.

Parameters
  • host – A dragonfly_core Building object that hosts these properties.

  • construction_set – A honeybee ConstructionSet object to specify all default constructions for the Faces of the Building. If None, the Building will use the honeybee default construction set, which is not representative of a particular building code or climate zone. Default: None.

Properties:
  • host

  • construction_set

ToString()[source]
add_default_ideal_air()[source]

Add a default IdealAirSystem to all children Room2Ds of this Story.

The identifier of the systems will be derived from the room identifiers.

apply_properties_from_dict(abridged_data, construction_sets)[source]

Apply properties from a BuildingEnergyPropertiesAbridged dictionary.

Parameters
  • abridged_data – A BuildingEnergyPropertiesAbridged dictionary (typically coming from a Model).

  • construction_sets – A dictionary of ConstructionSets with identifiers of the sets as keys, which will be used to re-assign construction_sets.

apply_properties_from_geojson_dict(data)[source]

Apply properties from a geoJSON dictionary.

Parameters

data – A dictionary representation of a geoJSON feature properties. Specifically, this should be the “properties” key describing a Polygon or MultiPolygon object.

averaged_program_type(identifier=None, timestep_resolution=1)[source]

Get a ProgramType that is averaged across all of the children Room2Ds.

The weights used in the averaging process are the floor area weights and they account for the multipliers on the child Story objects.

Parameters
  • identifier – A unique ID text string for the new averaged ProgramType. Must be < 100 characters and not contain any EnergyPlus special characters. This will be used to identify the object across a model and in the exported IDF. If None, the resulting ProgramType will use the identifier of the host Building. (Default: None)

  • timestep_resolution – An optional integer for the timestep resolution at which the schedules will be averaged. Any schedule details smaller than this timestep will be lost in the averaging process. Default: 1.

diversify(occupancy_stdev=20, lighting_stdev=20, electric_equip_stdev=20, gas_equip_stdev=20, hot_water_stdev=20, infiltration_stdev=20, schedule_offset=1, timestep=1)[source]

Diversify the ProgramTypes assigned to this Building’s Room2Ds.

This method uses a random number generator and gaussian distribution to generate loads that vary about the original “mean” programs. Note that the randomly generated values can be set to something predictable by using the native Python random.seed() method before running this method.

In addition to diversifying load values, approximately 2/3 of the schedules in the resulting Room2Ds will be offset from the mean by the input schedule_offset (1/3 ahead and another 1/3 behind).

Parameters
  • occupancy_stdev – A number between 0 and 100 for the percent of the occupancy people_per_area representing one standard deviation of diversification from the mean. (Default 20 percent).

  • lighting_stdev – A number between 0 and 100 for the percent of the lighting watts_per_area representing one standard deviation of diversification from the mean. (Default 20 percent).

  • electric_equip_stdev – A number between 0 and 100 for the percent of the electric equipment watts_per_area representing one standard deviation of diversification from the mean. (Default 20 percent).

  • gas_equip_stdev – A number between 0 and 100 for the percent of the gas equipment watts_per_area representing one standard deviation of diversification from the mean. (Default 20 percent).

  • hot_water_stdev – A number between 0 and 100 for the percent of the service hot water flow_per_area representing one standard deviation of diversification from the mean. (Default 20 percent).

  • infiltration_stdev – A number between 0 and 100 for the percent of the infiltration flow_per_exterior_area representing one standard deviation of diversification from the mean. (Default 20 percent).

  • schedule_offset – A positive integer for the number of timesteps at which all schedules of the resulting programs will be shifted - roughly 1/3 of the programs ahead and another 1/3 behind. (Default: 1).

  • timestep – An integer for the number of timesteps per hour at which the shifting is occurring. This must be a value between 1 and 60, which is evenly divisible by 60. 1 indicates that each step is an hour while 60 indicates that each step is a minute. (Default: 1).

duplicate(new_host=None)[source]

Get a copy of this object.

new_host: A new Building object that hosts these properties.

If None, the properties will be duplicated with the same host.

classmethod from_dict(data, host)[source]

Create BuildingEnergyProperties from a dictionary.

Note that the dictionary must be a non-abridged version for this classmethod to work.

Parameters
  • data – A dictionary representation of BuildingEnergyProperties.

  • host – A Building object that hosts these properties.

set_all_program_type_from_building_type(building_type)[source]

Set the children Room2Ds to have a program mix from a building_type.

Parameters

building_type – A text string for the type of building. This must appear under the BUILDING_TYPES constant of the honeybee_energy.lib.programtypes module to be successful.

set_all_room_2d_hvac(hvac, conditioned_only=True)[source]

Set all children Room2Ds of this Building to have the same HVAC system.

Parameters
  • hvac – An HVAC system with properties that will be assigned to all children Room2Ds.

  • conditioned_only – Boolean to note whether the input hvac should only be applied to rooms that are already conditioned. If False, the hvac will be applied to all rooms. (Default: True).

set_all_room_2d_program_type(program_type)[source]

Set all of the children Room2Ds of this Building to have the same ProgramType.

Parameters

program_type – A ProgramType to assign to all children Room2Ds.

set_all_room_2d_shw(shw)[source]

Set all children Room2Ds of this Building to have the same SHW system.

Parameters

shw – A Service Hot Water (SHW) system with properties that will be assigned to all children Room2Ds.

to_dict(abridged=False)[source]

Return Building energy properties as a dictionary.

Parameters

abridged – Boolean for whether the full dictionary of the Building should be written (False) or just the identifier of the the individual properties (True). Default: False.

property construction_set

Get or set the Building ConstructionSet object.

If not set, it will be the Honeybee default generic ConstructionSet.

property host

Get the Building object hosting these properties.