Thomas: The following code: import ifcopenshell ifc=ifcopenshell.open('File.ifc') for p in ifc.by_type('IfcPropertySingleValue'): if p.NominalValue == None: ifc.remove(p) ifc.write('NewFile.ifc') does exactly wht I was looking for. Thank you so much Xema
Hi. Inspired by this topic... https://sourceforge.net/p/ifcopenshell/discussion/1782717/thread/349bac7ab8/ (Add property to existing pset) ... I have written this code in order to DELETE null properties: import ifcopenshell ifc=ifcopenshell.open('File.ifc') #file attached to this post elements = ifc.by_type("IfcElement") for element in elements: for definition in element.IsDefinedBy: if definition.is_a('IfcRelDefinesByProperties'): property_set = definition.RelatingPropertyDefinition print(property_set.Name)...
Hi. Inspired by this topic... https://sourceforge.net/p/ifcopenshell/discussion/1782717/thread/349bac7ab8/ (Add property to existing pset) ... I have written this code in order to DELETE null properties: import ifcopenshell ifc=ifcopenshell.open('File.ifc') elements = ifc.by_type("IfcElement") for element in elements: for definition in element.IsDefinedBy: if definition.is_a('IfcRelDefinesByProperties'): property_set = definition.RelatingPropertyDefinition print(property_set.Name) for property in...
Hi. Inspired by this topic... https://sourceforge.net/p/ifcopenshell/discussion/1782717/thread/349bac7ab8/ (Add property to existing pset) ... I have written this code in order to DELETE null properties: import ifcopenshell ifc=ifcopenshell.open('File.ifc') elements = ifc.by_type("IfcElement") for element in elements: for definition in element.IsDefinedBy: if definition.is_a('IfcRelDefinesByProperties'): property_set = definition.RelatingPropertyDefinition print(property_set.Name) for property in...
Hi, Thomas: It works perfectly. Thank you
Hi Either an IfcStyledItem can be linked ¿How can be it done? ¿Is it as simple as adding an IfcStyledItem = ifcfile.createIfcStyledItem(body_representation, [Assign], 'Label') as shown in this answer? https://sourceforge.net/p/ifcopenshell/discussion/1782717/thread/5864f90d33/?limit=25#bb5f/778d I've added this code to the symple_wall_example.py # Wall creation: Define the wall shape as a polyline axis and an extruded area solid wall_placement = create_ifclocalplacement(ifcfile, relative_to=storey_placement)...
Hello: It's a shame that IfcFixedReferenceSweptAreaSolid is not implemented yet. But I've realized that, in the documentation you post, the function IfcSweptDiskSolid is ready, and it is usefull for my work. I've changed my solution and now it works fine. Thank you so much José Mª
Hi, I'm novice in python and ifcopenshell. I'm trying to extrude a generic shape (polyline_section) along an axis (polyline_axis). I'm working with IfcFixedReferenceSweptAreaSolid. An ifc is generated but no geometry is created. (functions create_ifcpolyline and create_ifcaxis2placement come from othe solution and work fine) ... point_list_section = [[0.0,0.0,0.0],[0.0,1.0,0.0],[2.0,1.0,0.0],[2.0,0.0,0.0],[0.0,0.0,0.0]] polyline_section = create_ifcpolyline(ifcfile, point_list_section) ifcclosedprofile...