honeybee_radiance.writer module

Methods to write to rad.

honeybee_radiance.writer.aperture_to_rad(aperture, blk=False, minimal=False)[source]

Generate a RAD string representation of an Aperture.

Note that the resulting string does not include modifier definitions. Nor does it include any states for dynamic geometry. However, it does include the shade geometry assigned to the Aperture.

Parameters
  • aperture – A honeybee Aperture for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the Aperture should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

  • minimal – Boolean to note whether the radiance string should be written in a minimal format (with spaces instead of line breaks). Default: False.

honeybee_radiance.writer.door_to_rad(door, blk=False, minimal=False)[source]

Generate a RAD string representation of a Door.

Note that the resulting string does not include modifier definitions. Nor does it include any states for dynamic geometry. However, it does include any of the shades assigned to the Door.

Parameters
  • door – A honeybee Door for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the Door should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

  • minimal – Boolean to note whether the radiance string should be written in a minimal format (with spaces instead of line breaks). Default: False.

honeybee_radiance.writer.face_to_rad(face, blk=False, minimal=False, exclude_sub_faces=False)[source]

Get Face as a Radiance string.

Note that the resulting string does not include modifier definitions. Nor does it include any states for dynamic geometry. However, it does include any of the shades assigned to the Face along with the Apertures and Doors in the Face.

Parameters
  • face – A honeybee Face for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the Face should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

  • minimal – Boolean to note whether the radiance string should be written in a minimal format (with spaces instead of line breaks). (Default: False).

  • exclude_sub_faces – Boolean to note whether Apertures and Doors should be excluded from the output string. (Default: False).

honeybee_radiance.writer.model_to_rad(model, blk=False, minimal=False)[source]

Generate a RAD string representation of a Model.

The resulting strings will include all geometry (Rooms, Faces, Shades, Apertures, Doors) and all modifiers. However, it does not include any states for dynamic geometry and will only write the default state for each dynamic object. To correctly account for dynamic objects, the model_to_rad_folder should be used.

Note that this method will also ensure that any Faces, Apertures, or Doors with Surface boundary condition only have one of such objects in the output string.

Parameters
  • model – A honeybee Model for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the geometry should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

  • minimal – Boolean to note whether the radiance string should be written in a minimal format (with spaces instead of line breaks). Default: False.

Returns

A tuple of two strings.

  • model_str: A radiance string that contains all geometry of the Model.

  • modifier_str: A radiance string that contains all of the modifiers in the model. These will be modifier_blk if blk is True.

honeybee_radiance.writer.model_to_rad_folder(model, folder=None, config_file=None, minimal=False, grids=None, views=None, full_match=False)[source]

Write a honeybee model to a rad folder.

The rad files in the resulting folders will include all geometry (Rooms, Faces, Shades, Apertures, Doors), all modifiers, and all states of dynamic objects. It also includes any SensorGrids and Views that are assigned to the model’s radiance properties.

Parameters
  • model – A honeybee Model for which radiance folder will be written.

  • folder – An optional folder to be used as the root of the model’s Radiance folder. If None, the files will be written into a sub-directory of the honeybee-core default_simulation_folder. This sub-directory is specifically: default_simulation_folder/[MODEL IDENTIFIER]/Radiance

  • config_file – An optional config file path to modify the default folder names. If None, folder.cfg in honeybee-radiance-folder will be used. (Default: None).

  • minimal – Boolean to note whether the radiance strings should be written in a minimal format (with spaces instead of line breaks). Default: False.

  • grids – A list of sensor grid names to filter the sensor grids in the model. Use this argument to indicate specific sensor grids that should be included. By default all the sensor grids will be exported. You can use wildcard symbols in names. Use relative path from inside grids folder.

  • views – A list of view files that should be exported to folder. Use this argument to limit what will be written to the radiance folder. You can use wildcard symbols in names. Use relative path from inside views folder.

  • full_match – A boolean to filter grids and views by their identifiers as full matches. Setting this to True indicates that wildcard symbols will not be used in the filtering of grids and views. In this case the names of grids and views are filtered as is. (Default: False).

honeybee_radiance.writer.room_to_rad(room, blk=False, minimal=False)[source]

Generate a RAD string representation of a Room.

This method will write all geometry associated with a Room including all Faces, Apertures, Doors, and Shades. However, it does not include modifiers for this geometry. Nor does it include any states for dynamic geometry and will only write the default state for each dynamic object.

Parameters
  • room – A honeybee Room for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the geometry should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

  • minimal – Boolean to note whether the radiance string should be written in a minimal format (with spaces instead of line breaks). Default: False.

honeybee_radiance.writer.shade_mesh_to_rad(shade_mesh, blk=False)[source]

Generate a RAD string representation of a ShadeMesh.

Note that the resulting string does not include modifier definitions.

Parameters
  • shade – A honeybee ShadeMesh for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the Shade should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

honeybee_radiance.writer.shade_to_rad(shade, blk=False, minimal=False)[source]

Generate a RAD string representation of a Shade.

Note that the resulting string does not include modifier definitions. Nor does it include any states for dynamic geometry.

Parameters
  • shade – A honeybee Shade for which a RAD representation will be returned.

  • blk – Boolean to note whether the “blacked out” version of the Shade should be output, which is useful for direct studies and isolation studies to understand the contribution of individual apertures.

  • minimal – Boolean to note whether the radiance string should be written in a minimal format (with spaces instead of line breaks). Default: False.