topologicpy.Honeybee module

class topologicpy.Honeybee.Honeybee

Bases: object

Methods

ByHBJSONDictionary(dictionary[, ...])

Import an HBJSON model from a python dictionary and return a python dictionary.

ByHBJSONPath(path[, includeRooms, ...])

Import an HBJSON model from a file path and return a python dictionary.

ByHBJSONString(string[, includeRooms, ...])

Import an HBJSON model from a file path and return a python dictionary.

ConstructionSetByIdentifier(id)

Returns the built-in construction set by the input identifying string.

ConstructionSets()

Returns the list of built-in construction sets

ExportToHBJSON(model, path[, overwrite])

Exports the input HB Model to a file.

ModelByTopology(tpBuilding[, ...])

Creates an HB Model from the input Topology.

ProgramTypeByIdentifier(id)

Returns the program type by the input identifying string.

ProgramTypes()

Returns the list of available built-in program types.

String(model)

Returns the string representation of the input model.

static ByHBJSONDictionary(dictionary, includeRooms: bool = True, includeFaces: bool = True, includeShades: bool = True, includeApertures: bool = True, includeDoors: bool = True, includeOrphanedRooms: bool = True, includeOrphanedFaces: bool = True, includeOrphanedShades: bool = True, includeOrphanedApertures: bool = True, includeOrphanedDoors: bool = True, tolerance: float = 0.0001, silent: bool = False)

Import an HBJSON model from a python dictionary and return a python dictionary. See: https://github.com/ladybug-tools/honeybee-schema/wiki/1.1-Model-Schema

Parameters
dictionarydict

The HBJSON model as a Python dictionary (e.g., loaded via json.load).

includeRoomsbool, optional

If True, parse rooms and attempt to create one Cell per room. Default is True.

includeFacesbool, optional

If True, include top-level planar faces found outside rooms (e.g., at root “faces”). Default is True.

includeShadesbool, optional

If True, include context/standalone shades (e.g., context_geometry.shades). Default is True.

includeAperturesbool, optional

If True, include room apertures (e.g., windows) as separate Face objects (not cut from hosts). Default is True.

includeDoorsbool, optional

If True, include room doors as separate Face objects (not cut from hosts). Default is True.

includeOrphanedRoomsbool, optional

If True, include the topology of the room when a room fails to close as a Cell. This may be a Shell or a Cluster. Default is True.

includeOrphanedFacesbool, optional

If True, include planar faces listed at the HBJSON root (e.g., “faces”). Default is True.

includeOrphanedShadesbool, optional

If True, include shades listed at the HBJSON root (e.g., “orphaned_shades”). Default is True.

includeOrphanedAperturesbool, optional

If True, include apertures listed at the HBJSON root (e.g., “orphaned_apertures”). Default is True.

includeOrphanedDoorsbool, optional

If True, include doors listed at the HBJSON root (e.g., “orphaned_doors”). Default is True.

tolerancefloat , optional

The desired tolerance. Default is 0.0001.

silentbool , optional

If set to True, error and warning messages are suppressed. Default is False.

Returns
dict

The created cluster of vertices, edges, faces, and cells. - ‘rooms’: list of Cells (one per successfully closed room) - ‘faces’: list of Faces (all faces that make up the rooms) - ‘shades’: list of Faces (all shade faces) - ‘apertures’: list of Faces (all apertures, never cut from hosts) - ‘doors’: list of Faces (all doors, never cut from hosts) - ‘orphanedRooms’: list of Topologies (context/top-level topologies (e.g. Shells or Clustser) that failed to form a Cell) - ‘orphanedFaces’: list of Faces (context/top-level faces + host faces of rooms that failed to form a Cell) - ‘orphanedShades’: list of Faces (context/top-level shade faces that failed to have a parent cell) - ‘orphanedApertures’: list of Faces (apertures that failed to have a parent face) - ‘orphanedDoors’: list of Faces (doors that failed to have a parent face) - ‘properties’: hierarchical dict copied verbatim from HBJSON[‘properties’]

static ByHBJSONPath(path: str, includeRooms: bool = True, includeFaces: bool = True, includeShades: bool = True, includeApertures: bool = True, includeDoors: bool = True, includeOrphanedRooms: bool = True, includeOrphanedFaces: bool = True, includeOrphanedShades: bool = True, includeOrphanedApertures: bool = True, includeOrphanedDoors: bool = True, tolerance: float = 0.0001, silent: bool = False)

Import an HBJSON model from a file path and return a python dictionary. See: https://github.com/ladybug-tools/honeybee-schema/wiki/1.1-Model-Schema

Parameters
dictionarydict

The HBJSON model as a Python dictionary (e.g., loaded via json.load).

includeRoomsbool, optional

If True, parse rooms and attempt to create one Cell per room. Default is True.

includeFacesbool, optional

If True, include top-level planar faces found outside rooms (e.g., at root “faces”). Default is True.

includeShadesbool, optional

If True, include context/standalone shades (e.g., context_geometry.shades). Default is True.

includeAperturesbool, optional

If True, include room apertures (e.g., windows) as separate Face objects (not cut from hosts). Default is True.

includeDoorsbool, optional

If True, include room doors as separate Face objects (not cut from hosts). Default is True.

includeOrphanedRoomsbool, optional

If True, include the topology of the room when a room fails to close as a Cell. This may be a Shell or a Cluster. Default is True.

includeOrphanedFacesbool, optional

If True, include planar faces listed at the HBJSON root (e.g., “faces”). Default is True.

includeOrphanedShadesbool, optional

If True, include shades listed at the HBJSON root (e.g., “orphaned_shades”). Default is True.

includeOrphanedAperturesbool, optional

If True, include apertures listed at the HBJSON root (e.g., “orphaned_apertures”). Default is True.

includeOrphanedDoorsbool, optional

If True, include doors listed at the HBJSON root (e.g., “orphaned_doors”). Default is True.

tolerancefloat , optional

The desired tolerance. Default is 0.0001.

silentbool , optional

If set to True, error and warning messages are suppressed. Default is False.

Returns
dict

The created cluster of vertices, edges, faces, and cells. - ‘rooms’: list of Cells (one per successfully closed room) - ‘faces’: list of Faces (all faces that make up the rooms) - ‘shades’: list of Faces (all shade faces) - ‘apertures’: list of Faces (all apertures, never cut from hosts) - ‘doors’: list of Faces (all doors, never cut from hosts) - ‘orphanedRooms’: list of Topologies (context/top-level topologies (e.g. Shells or Clustser) that failed to form a Cell) - ‘orphanedFaces’: list of Faces (context/top-level faces + host faces of rooms that failed to form a Cell) - ‘orphanedShades’: list of Faces (context/top-level shade faces that failed to have a parent cell) - ‘orphanedApertures’: list of Faces (apertures that failed to have a parent face) - ‘orphanedDoors’: list of Faces (doors that failed to have a parent face) - ‘properties’: hierarchical dict copied verbatim from HBJSON[‘properties’]

static ByHBJSONString(string, includeRooms: bool = True, includeFaces: bool = True, includeShades: bool = True, includeApertures: bool = True, includeDoors: bool = True, includeOrphanedRooms: bool = True, includeOrphanedFaces: bool = True, includeOrphanedShades: bool = True, includeOrphanedApertures: bool = True, includeOrphanedDoors: bool = True, tolerance: float = 0.0001, silent: bool = False)

Import an HBJSON model from a file path and return a python dictionary. See: https://github.com/ladybug-tools/honeybee-schema/wiki/1.1-Model-Schema

Parameters
stringstr

The HBJSON model as a string.

includeRoomsbool, optional

If True, parse rooms and attempt to create one Cell per room. Default is True.

includeFacesbool, optional

If True, include top-level planar faces found outside rooms (e.g., at root “faces”). Default is True.

includeShadesbool, optional

If True, include context/standalone shades (e.g., context_geometry.shades). Default is True.

includeAperturesbool, optional

If True, include room apertures (e.g., windows) as separate Face objects (not cut from hosts). Default is True.

includeDoorsbool, optional

If True, include room doors as separate Face objects (not cut from hosts). Default is True.

includeOrphanedRoomsbool, optional

If True, include the topology of the room when a room fails to close as a Cell. This may be a Shell or a Cluster. Default is True.

includeOrphanedFacesbool, optional

If True, include planar faces listed at the HBJSON root (e.g., “faces”). Default is True.

includeOrphanedShadesbool, optional

If True, include shades listed at the HBJSON root (e.g., “orphaned_shades”). Default is True.

includeOrphanedAperturesbool, optional

If True, include apertures listed at the HBJSON root (e.g., “orphaned_apertures”). Default is True.

includeOrphanedDoorsbool, optional

If True, include doors listed at the HBJSON root (e.g., “orphaned_doors”). Default is True.

tolerancefloat , optional

The desired tolerance. Default is 0.0001.

silentbool , optional

If set to True, error and warning messages are suppressed. Default is False.

Returns
dict

The created cluster of vertices, edges, faces, and cells. - ‘rooms’: list of Cells (one per successfully closed room) - ‘faces’: list of Faces (all faces that make up the rooms) - ‘shades’: list of Faces (all shade faces) - ‘apertures’: list of Faces (all apertures, never cut from hosts) - ‘doors’: list of Faces (all doors, never cut from hosts) - ‘orphanedRooms’: list of Topologies (context/top-level topologies (e.g. Shells or Clustser) that failed to form a Cell) - ‘orphanedFaces’: list of Faces (context/top-level faces + host faces of rooms that failed to form a Cell) - ‘orphanedShades’: list of Faces (context/top-level shade faces that failed to have a parent cell) - ‘orphanedApertures’: list of Faces (apertures that failed to have a parent face) - ‘orphanedDoors’: list of Faces (doors that failed to have a parent face) - ‘properties’: hierarchical dict copied verbatim from HBJSON[‘properties’]

static ConstructionSetByIdentifier(id)

Returns the built-in construction set by the input identifying string.

Parameters
idstr

The construction set identifier.

Returns
HBConstructionSet

The found built-in construction set.

static ConstructionSets()

Returns the list of built-in construction sets

Returns
list

The list of built-in construction sets.

static ExportToHBJSON(model, path, overwrite=False)

Exports the input HB Model to a file.

Parameters
modelHBModel

The input HB Model.

pathstr

The location of the output file.

overwritebool , optional

If set to True this method overwrites any existing file. Otherwise, it won’t. Default is False.

Returns
bool

Returns True if the operation is successful. Returns False otherwise.

static ModelByTopology(tpBuilding, tpShadingFacesCluster=None, buildingName: str = 'Generic_Building', defaultProgramIdentifier: str = 'Generic Office Program', defaultConstructionSetIdentifier: str = 'Default Generic Construction Set', coolingSetpoint: float = 25.0, heatingSetpoint: float = 20.0, humidifyingSetpoint: float = 30.0, dehumidifyingSetpoint: float = 55.0, roomNameKey: str = 'TOPOLOGIC_name', roomTypeKey: str = 'TOPOLOGIC_type', apertureTypeKey: str = 'TOPOLOGIC_type', addSensorGrid: bool = False, mantissa: int = 6)

Creates an HB Model from the input Topology.

Parameters
tpBuildingtopologic_core.CellComplex or topologic_core.Cell

The input building topology.

tpShadingFaceClustertopologic_core.Cluster , optional

The input cluster for shading faces. Default is None.

buildingNamestr , optional

The desired name of the building. Default is “Generic_Building”.

defaultProgramIdentifier: str , optional

The desired default program identifier. Default is “Generic Office Program”.

defaultConstructionSetIdentifier: str , optional

The desired default construction set identifier. Default is “Default Generic Construction Set”.

coolingSetpointfloat , optional

The desired HVAC cooling set point in degrees Celsius. Default is 25.

heatingSetpointfloat , optional

The desired HVAC heating set point in degrees Celsius. Default is 20.

humidifyingSetpointfloat , optional

The desired HVAC humidifying set point in percentage. Default is 55.

roomNameKeystr , optional

The dictionary key under which the room name is stored. Default is “TOPOLOGIC_name”.

roomTypeKeystr , optional

The dictionary key under which the room type is stored. Default is “TOPOLOGIC_type”.

apertureTypeKeystr , optional

The dictionary key under which the aperture type is stored. Default is “TOPOLOGIC_type”.

addSensorGridbool , optional

If set to True a sensor grid is add to horizontal surfaces. Default is False.

mantissaint , optional

The number of decimal places to round the result to. Default is 6.

Returns
HBModel

The created HB Model

static ProgramTypeByIdentifier(id)

Returns the program type by the input identifying string.

Parameters
idstr

The identifiying string.

Returns
HBProgram

The found built-in program.

static ProgramTypes()

Returns the list of available built-in program types.

Returns
list

The list of available built-in program types.

static String(model)

Returns the string representation of the input model.

Parameters
modelHBModel

The input HB Model.

Returns
dict

A dictionary representing the input HB Model.