honeybee_doe2.cli.translate module

honeybee-doe2 translation commands.

honeybee_doe2.cli.translate.constructions_from_inp(construction_inp, abridged=False, array=False, indent=None, output_file=None, full=True, dictionary=True)[source]

Translate all constructions in an INP file to a honeybee JSON.

Parameters:
  • construction_inp – Full path to a Construction INP file.

  • array – Boolean to note whether a the output JSON should be an array of construction objects or whether it should be a dictionary where each key is the identifier of the construction and each value is the construction object. The dictionary format is the one used by honeybee-standards and is recommended when writing INP constructions into the user standards library. (Default: False).

  • indent – Optional integer to specify the indentation in the output JSON file. Specifying an value here can produce more read-able JSONs. (Default: None).

  • output_file – Optional JSON file path to output the JSON string of the translation. If None, the string will be returned from this function.

honeybee_doe2.cli.translate.constructions_to_inp(construction_json, output_file=None)[source]

Translate a Construction JSON file to an INP.

Parameters:
  • construction_json – Full path to a Construction JSON file. This file should either be an array of non-abridged Constructions or a dictionary where the values are non-abridged Constructions.

  • output_file – Optional INP file to output the string of the translation. If None, it will be returned from this method. (Default: None).

honeybee_doe2.cli.translate.materials_from_inp(material_inp, array=False, indent=None, output_file=None, dictionary=True)[source]

Translate all materials in an INP file to a honeybee JSON.

The resulting JSON can be written into a user standards folder to add the materials to a users standards library.

Parameters:
  • material_inp – Full path to an INP file. Only the materials in this file will be extracted.

  • array – Boolean to note whether a the output JSON should be an array of material objects or whether it should be a dictionary where each key is the identifier of the material and each value is the material object. The dictionary format is the one used by honeybee-standards and is recommended when writing INP materials into the user standards library. (Default: False).

  • indent – Optional integer to specify the indentation in the output JSON file. Specifying an value here can produce more read-able JSONs. (Default: None).

  • output_file – Optional JSON file to output the string of the translation. If None, it will be returned from this method. (Default: None).

honeybee_doe2.cli.translate.model_from_inp(inp_file, output_file=None)[source]

Translate an INP file to a Honeybee Model as a HBJSON.

Parameters:
  • inp_file – Full path to an INP file.

  • output_file – Optional HBJSON file path to output the string of the translation. If None, the string will be returned from this function.

honeybee_doe2.cli.translate.model_to_inp(model_file, sim_par_json=None, hvac_mapping='Story', exclude_interior_walls=False, exclude_interior_ceilings=False, equest_version='3.65', output_file=None, include_interior_walls=True, include_interior_ceilings=True)[source]

Translate a Honeybee Model to an INP file.

Parameters:
  • model_file – Full path to a Honeybee Model file (HBJSON or HBpkl).

  • sim_par_json – Full path to a honeybee-doe2 SimulationPar JSON that describes all of the settings for the simulation. If None, default parameters will be generated. (Default: None).

  • hvac_mapping

    Text to indicate how HVAC systems should be assigned to the exported model. Story will assign one HVAC system for each distinct level polygon, Model will use only one HVAC system for the whole model and AssignedHVAC will follow how the HVAC systems have been assigned to the Rooms.properties.energy.hvac. Choose from the following.

    • Room

    • Story

    • Model

    • AssignedHVAC

  • exclude_interior_walls – Boolean to note whether interior walls should be excluded from the export. (Default: False).

  • exclude_interior_ceilings – Boolean to note whether interior ceilings should be excluded from the export. (Default: False).

  • equest_version – Optional text string to denote the version of eQuest for which the INP definition will be generated. If unspecified or unrecognized, the latest version of eQuest will be used. (Default: False).

  • output_file – Optional INP file path to output the INP string of the translation. If None, the string will be returned from this function.

honeybee_doe2.cli.translate.schedules_from_inp(schedule_inp, array=False, indent=None, output_file=None, dictionary=True)[source]

Translate all schedules in an INP file to a honeybee JSON.

Parameters:
  • schedule_inp – Full path to a Schedule INP file.

  • array – Boolean to note whether a the output JSON should be an array of schedule objects or whether it should be a dictionary where each key is the identifier of the schedule and each value is the schedule object. The dictionary format is the one used by honeybee-standards and is recommended when writing INP schedules into the user standards library. (Default: False).

  • indent – Optional integer to specify the indentation in the output JSON file. Specifying an value here can produce more read-able JSONs. (Default: None).

  • output_file – Optional JSON file path to output the JSON string of the translation. If None, the string will be returned from this function.

honeybee_doe2.cli.translate.schedules_to_inp(schedule_json, output_file=None)[source]

Translate a Schedule JSON file to an INP.

Parameters:
  • schedule_json – Full path to a Schedule JSON file. This file should either be an array of non-abridged Schedules or a dictionary where the values are non-abridged Schedules.

  • output_file – Optional INP file path to output the INP string of the translation. If None, the string will be returned from this function.