honeybee_designbuilder.cli.translate module¶
honeybee-designbuilder translation commands.
- honeybee_designbuilder.cli.translate.model_to_dsbxml(model_file, xml_template='Default', program_name=None, output_file=None)[source]¶
Translate a Honeybee Model to an DsbXML file.
- Parameters:
model_file – Full path to a Honeybee Model file (HBJSON or HBpkl).
xml_template –
Text for the type of template file to be used to write the dsbXML. Different templates contain different amounts of default assembly library data, which may be needed in order to import the dsbXML into older versions of DesignBuilder. However, this data can greatly increase the size of the resulting dsbXML file. Choose from the following options.
Default - a minimal file that imports into the latest versions
Assembly - the Default plus an AssemblyLibrary with typical objects
Full - a large file with all libraries that can be imported to version 7.3
program_name – Optional text to set the name of the software that will appear under a comment in the XML to identify where it is being exported from. This can be set things like “Ladybug Tools” or “Pollination” or some other software in which this DsbXML export capability is being run. If None, no comment will appear. (Default: None).
output_file – Optional dsbXML file path to output the dsbXML string of the translation. If None, the string will be returned from this function.