honeybee_doe2.programtype module

honeybee-doe2 program type translators.

honeybee_doe2.programtype.program_type_to_inp(program_type, switch_dict=None)[source]

Translate a ProgramType into a dictionary used to write INP switch statements.

Parameters:
  • program_type – A honeybee-energy ProgramType definition.

  • switch_dict – An optional dictionary with INP keywords as keys (such as PEOPLE-SCHEDULE or AREA/PERSON or LIGHTING-W/AREA). The values of the dictionary should be lists of switch statement text strings, such as ‘case “conf”: #SI(“Small Off Occ”, “SPACE”, “PEOPLE-SCHEDULE”)’. Specifying an input dictionary here can be used to build up switch statements for all program types across a model.

Returns:

An dictionary with INP keywords as keys (such as PEOPLE-SCHEDULE or AREA/PERSON). The values of the dictionary are lists of switch statement text strings, such as ‘case “conf”: #SI(“Small Off Occ”, “SPACE”, “PEOPLE-SCHEDULE”)’.

honeybee_doe2.programtype.switch_dict_to_space_inp(switch_dict)[source]

Translate a switch statement dictionary into INP strings for the SPACE.

Parameters:

switch_dict – An dictionary with INP keywords as keys (such as PEOPLE-SCHEDULE or AREA/PERSON or LIGHTING-W/AREA). The values of the dictionary should be lists of switch statement text strings, such as ‘case “conf”: #SI(“Small Off Occ”, “SPACE”, “PEOPLE-SCHEDULE”)’.

Returns:

A text string to be written into an INP file. This should go at the top of the description of Floors / Spaces.

honeybee_doe2.programtype.switch_dict_to_zone_inp(switch_dict)[source]

Translate a switch statement dictionary into INP strings for the ZONE.

Parameters:

switch_dict – An dictionary with INP keywords as keys (such as HEAT-TEMP-SCH or DESIGN-HEAT-T or OUTSIDE-AIR-FLOW). The values of the dictionary should be lists of switch statement text strings, such as ‘case “conf”: #SI(“Small Off HtgStp”, “SPACE”, “HEAT-TEMP-SCH”)’.

Returns:

A text string to be written into an INP file. This should go at the top of the description of HVAC Systems / Zones.