Overwriting constructions in database
Re: Overwriting constructions in database
There's no direct way of changing a surface type. Surface types are based on the geometry you have in your model.
Re: Overwriting constructions in database
Hello,
This thread was very helpful! I have a few related questions:
1. When setting 'g_value' using 'set_properties()', what exactly is this setting? I have been trying to use it and I can see it setting the 'g_value' by using 'get_properties()', but the g-value in the GUI does not change. What is the difference between these two properties?
2. Calling 'get_g_values()' on a construction object raises an AttributeError:
How should I call this correctly? I wasn't able to find an example in the cdb example scripts.
3. What exactly is the bug with 'set_properties()' on cdb objects? Some clarification on this would be great to understand what I should be looking out for when using it.
Many thanks,
Izzy
This thread was very helpful! I have a few related questions:
1. When setting 'g_value' using 'set_properties()', what exactly is this setting? I have been trying to use it and I can see it setting the 'g_value' by using 'get_properties()', but the g-value in the GUI does not change. What is the difference between these two properties?
2. Calling 'get_g_values()' on a construction object raises an AttributeError:
Code: Select all
AttributeError: 'VECdbConstruction' object has no attribute 'get_g_values'3. What exactly is the bug with 'set_properties()' on cdb objects? Some clarification on this would be great to understand what I should be looking out for when using it.
Many thanks,
Izzy
Re: Overwriting constructions in database
Hi,
1. This is the g-value you see in the 'regulation' tab. 'get_g_values() will give you a dictionary of three g-values, keys are 'bs_en_410', 'building_regulations', 'bfrc'.
2. Should be straightforwardly construction.get_g_values(). What version of the VE are you using? This particular method is not available in older versions of the API.
3. If I remember correctly, the properties were sometimes not retained after you had set them from a script. This was fixed for 2018 FP2.
Hope that helps.
1. This is the g-value you see in the 'regulation' tab. 'get_g_values() will give you a dictionary of three g-values, keys are 'bs_en_410', 'building_regulations', 'bfrc'.
2. Should be straightforwardly construction.get_g_values(). What version of the VE are you using? This particular method is not available in older versions of the API.
3. If I remember correctly, the properties were sometimes not retained after you had set them from a script. This was fixed for 2018 FP2.
Hope that helps.
Re: Overwriting constructions in database
Tian, I am having this same issue. There are no surface types which are ext_glazing, and removing the if statement from that piece of code doesn't work (assigning a glazing construction to the surface on which it lies doesn't work - it results in the error "invalid construction type for the surface"). Assigning it to the opening/window object doesn't work either.Tian wrote: Fri Apr 05, 2019 9:54 pm 2. I looked at at the sample of assign_to_bodies, and the code below didnt work well, it didnt successfully assign the construction.I printed suface.type and there is no surface type as ext_glazing, so I assumed this is the reason why the construction was not assigned. So I am wondering is there a way to solve this?Code: Select all
for surface in surfaces: # Only proceed to assign a construction if it's external glazing if surface.type == iesve.VESurface_type.ext_glazing: # Get the first glazing construction we can find construction = project.get_construction(ids[0], c_class) # Assign the glazing construction to the external glazing body.assign_construction(construction, surface)
It doesn't seem like glazing constructions can be assigned. Have you had any luck?
Re: Overwriting constructions in database
I'm running 2017 and running get_g_values() on a construction object returns an attribute error. Does this function only work in 2018?Rhind wrote: Thu May 23, 2019 8:40 am 2. Should be straightforwardly construction.get_g_values(). What version of the VE are you using? This particular method is not available in older versions of the API.
Code: Select all
AttributeError: 'VECdbConstruction' object has no attribute 'get_g_values'
Re: Overwriting constructions in database
Yes, I think it was new in 2018.

