I’m working on a project where I’m using a gbXML from Revit to calculate inside area values in other software.
The problem I’m having is that the dimensions in the gbXML are different from the dimensions in Revit.
I have created a room in Revit which is 5000x5000mm, in the export model option I have set the boundary location at wall finish. When I open the gbXML in Rhino the sides of my room have slightly different values, there’s a difference of 3.28mm.
This is most likely happening because of the tolerance and also using the conversation to feet and inches in Revit. Can you try to export the model as HBJSON and see if you still get the difference? That way we know if this is happening because of the Revit plugin or if there is something about the gbXML file format.
Thank you, @sanderr! If I understand your response correctly this issue only happens in the gbXML files. Can you upload the HBJSON and gbXML files here so we can have a look? I don’t know how much can be done on our end for the gbXML translation routine and we use the OpenStudio SDK for the translation. @chriswmackey knows more and should be able to help after checking the files.
This is the function that governs all unit conversions that happen across Honeybee and Dragonfly:
It looks like the conversion factor for feet (0.305) could use some more decimal places if people want accuracy down to the millimeter. I guess I originally chose these values based on EnergyPlus’s native tolerance of 1 centimeter but I realize this is pretty coarse for other engines and applications.
@mostapha unfortunately I can’t use HBJSON. The software I’m using is for calculating energy performance for Dutch building regelations and can only import gbXML files. For now I’m trying to use gbXML files from Revit models, the energy performance program then calculates all the needed areas and exports them to a webapplication, which is used to make the final calculation. This has proven to be quite difficult because of the bad gbXML’s I was getting from Revit, but for now the Pollination plug-in solves this issue! (except for the small difference in millimeters)
Hi @sanderr! Thank you for the detailed explanation. If the application has a standard input for surface areas and other entities that it subtracts from a gbXML model, we can develop an app to do the calculation using an HBJSON as the input. Glad to hear that the Revit plugin has resolved part of the issue.
And as @chriswmackey mentioned we should be able to solve the issue with the area for you so you can use the gbXML workflow as needed.
I have just merged in a fix with the more accurate conversion factor for feet:
So it will be included in the next update of the Revit plugin. In the meantime, you can get around the issue if you have both the Revit and Rhino plugin. All you have to do is export the model from Revit as a HBJSON, open it in the Rhino plugin, change the units IN RHINO to be millimeters, and then save the model as gbXML from the Rhino plugin. I realize it’s an extra step but you hopefully won’t have to wait too long for the next Revit plugin release.
I’m not sure if the fix is actually there since Github Actions have been broken for most of the last 2 days and I only just got the core libraries to be compatible with one another across their releases a few minutes ago. So you might just want to do another release at the end of today just to be sure.