If you're reading this, we've just migrated servers! If anything looks broken please email dion@thinkmoult.com :)
IfcOpenShell add an IfcClassificationReference
How do you add an IfcClassificationReference using the ifcopenshell.api
?
Tagged:
Comments
This?
https://sourcegraph.com/search?q=context:global+add_classification+repo:^github\.com/IfcOpenShell/IfcOpenShell$+file:src/ifcopenshell-python&patternType=standard
https://github.com/IfcOpenShell/IfcOpenShell/blob/v0.7.0/src/ifcopenshell-python/test/api/classification/test_add_classification_reference.py#L25
@Moult
Thanks! Works perfect! :-), I see it's even possible to get it from a classification file in your script.
I now all create it from a CSV file
Is there any documentation for the
ifcopenshell.api
I found this:
https://github.com/IfcOpenShell/IfcOpenShell/tree/v0.7.0/src/ifcopenshell-python/test/api
But i would like to know if it's possible with the ifcopenshell.api to add a IfcBeamType instance with an IfcParametrizedProfile definition and if I there any examples available.
Don;t really understand how to search in the link @theoryshaw gave
Found this:
https://sourcegraph.com/search?q=context:global+beam+repo:^github\.com/IfcOpenShell/IfcOpenShell$+file:src/ifcopenshell-python&patternType=standard
But don't understand how to create a profile
So far I managed to get to here
It outputs this:
Clueless how to add a profile, but should be possible since there is a generated library made from BOLTS?
@bernd Do you perhaps know how to create an IfcBeamType instance from with an IfcParametrizedProfileDef using IfcMaterialProfileSetUsage?
sorry I've never worked with ifc types in ifcos and python so far ...
@Coen
stummbled over IfcClassificationReference as well and found this. Do you still use it? How does BIMCollab Zoom displays it? How about other viewers.
ATM for us the classification is written in a normal text pset.property. I do not really know what is the advantage of using a separate ifc entity for this?
cheers bernd
If I understand it correctly, the advantage is you could use external classificition files to reference IFC entities. From the BS documentation:
In the Netherlands the nlsfb is used a lot to classify. I think you could load a certain .txt file into Revit/Archicad whatever and then you could a classificion menu. I think BlenderBIM also has this. But I never tried it.
https://www.bimloket.nl/p/715/Tabellen
Here you can download these classifcations, this organization also maintains these files. See the last update is from 2021.
Do you have a simple example file? I would like to know how this looks in BIMCollab Zoom before starting to try something ...
BTW:
Switzerland starts something too ... https://www.crb.ch/Normen-Standards/Baukostenplaene/eBKP-Plugin.html Since we use our own code to classify (which is for sure based on IfcOpenShell) I might switch from PSet.Property to this IfcClassificationReference to be on the same road as all the others ...
Do you mean ifc file or .txt classification file?
The schependomlaan.ifc is really classified neatly:
makes it really easy to filter out structural elements and other stuff.
The benefits of using IfcClassificationReference over a property set are:
That all totally makes sense. Great stuff. I will jump in the IfcClassificationRace ... I will use swiss classification system ...
Ahh thanks for the schependomlaan hint