ifc mapping

This forum section is only for IFC-related issues
Post Reply
User avatar
hardeeprai
Posts: 177
Joined: Sun May 23, 2010 2:41 pm
Location: Ludhiana, Punjab, India
Contact:

ifc mapping

Post by hardeeprai »

Is ifc4 import/export works in FreeCAD, as IfcOpenShell has support for ifc4.

Which files (in source code repository) maps FreeCAD data to IfcOpenShell?
--
H.S.Rai
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: ifc mapping

Post by bernd »

User avatar
hardeeprai
Posts: 177
Joined: Sun May 23, 2010 2:41 pm
Location: Ludhiana, Punjab, India
Contact:

Re: ifc mapping

Post by hardeeprai »

Thank you.

Will go through, try to understand, and if there is any query, will come back.

In the mean time, if anyone has any suggestion, can give me some direction, pointer to other information available elsewhere, which could be useful.

I wanted to see "capacity of structural members" in ifc files. Is that possible?

I will calculate Moment carrying capacity of I-section used as beam or Reinforced Beam, and that should become property of structural member. Like wise a column will be having equivalent of P-M Load-Moment interaction Curve.
--
H.S.Rai
User avatar
yorik
Founder
Posts: 13665
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: ifc mapping

Post by yorik »

At the top of the importIFC.py file you'll see a "conversion table" that maps FreeCAD types <-> IFC types.
One of the things I'll do soon (in fact, doing this right now) is to allow all Arch/BIM objects to have any IFC type, so you can draw a wall and make it export as a column.

Regarding structural properties, the IFC format itself allows you to export just any custom properties with any object. You can group these properties into a property set that you define yourself. At the moment, FreeCAD will export everything it finds in the IfcAttributes property that all Arch/BIM objects have. So to have something exported automatically, just add to any object's IfcAttribute, for example like this:

Code: Select all

myDict = myObject.IfcAttributes
myDict["MyNewPropertyName":"IfcText(Hello, world!)"]
myObject.IfcAttributes = myDict
When exported to IFC, an IfcPropertySingleValue of name MyNewPropertyName and type IfcText will be added automatically. The syntax is still a bit cumberstone and this system doesn't support custom property sets yet, but I'm working on it.

Now, of course, the whole thing is that other applications won't be aware of the custom properties you add. In the best case, they will read it and keep its value stored somewhere. So one has to look at the IFC specs if there is something "standard" to deal with such structural properties, or analyze the IFC file produced by other structural BIM apps to see how they do it, and we can try doing the same.
User avatar
cnirbhay
Posts: 115
Joined: Wed Aug 17, 2016 4:24 pm

Re: ifc mapping

Post by cnirbhay »

yorik wrote: Thu May 10, 2018 1:44 pm Now, of course, the whole thing is that other applications won't be aware of the custom properties you add. In the best case, they will read it and keep its value stored somewhere. So one has to look at the IFC specs if there is something "standard" to deal with such structural properties, or analyze the IFC file produced by other structural BIM apps to see how they do it, and we can try doing the same.
I agree. I did some workout for this on Revit. I tried custom mapping but it is very limited. Revit performs mapping only to those IFC entities which it recognises. For eg: A column could be mapped to IfcBeam or IfcFurniture, etc but when I tried mapping it to IfcStructuraItem or IfcStructuralAnalysisModel, the export turned out into IfcBuildingElementProxy. I'm doubtful there must be some other mapping table that Revit uses somewhere in its hidden backend other than the 'exportlayers-ifc-IAI' file.

Please see the below attached screenshots.

Image
Image
Image
Image
[img
Screenshot (355)_LI.jpg
Screenshot (355)_LI.jpg (874.71 KiB) Viewed 2259 times
][/img]

Thanks.

Regards.
Attachments
Screenshot (360)_LI.jpg
Screenshot (360)_LI.jpg (441.63 KiB) Viewed 2259 times
Screenshot (359)_LI.jpg
Screenshot (359)_LI.jpg (890.74 KiB) Viewed 2259 times
Screenshot (358)_LI.jpg
Screenshot (358)_LI.jpg (379.41 KiB) Viewed 2259 times
Screenshot (357)_LI.jpg
Screenshot (357)_LI.jpg (404.63 KiB) Viewed 2259 times
User avatar
yorik
Founder
Posts: 13665
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: ifc mapping

Post by yorik »

I just changed things in FreeCAD yesterday, now each BIM/Arch object has an IfcRole property, instead of its former Role property. This IfcRole can be any IFC entity derived from IfcProduct, which are the ones that can have a Representation. I think this will make things clearer and more universal (ie. any FreeCAD Arch object can be exported to any IFC entity). In the BIM WB there is now a new "Ifc Element Manager" tool to manage IFC mappings all at once.
User avatar
bitacovir
Veteran
Posts: 1570
Joined: Sat Apr 19, 2014 6:23 am
Contact:

Re: ifc mapping

Post by bitacovir »

yorik wrote: Sun May 13, 2018 6:36 pm I just changed things in FreeCAD yesterday, now each BIM/Arch object has an IfcRole property, instead of its former Role property. This IfcRole can be any IFC entity derived from IfcProduct, which are the ones that can have a Representation. I think this will make things clearer and more universal (ie. any FreeCAD Arch object can be exported to any IFC entity). In the BIM WB there is now a new "Ifc Element Manager" tool to manage IFC mappings all at once.
These changes are for V0.17 or 0.18?
::bitacovir::
==================
One must be absolutely modern.
Arthur Rimbaud (A Season in Hell -1873)

Canal Youtube Grupo Telegram de FreeCAD Español

My personal web site
My GitHub repository
Mini Airflow Tunnel Project
User avatar
chakkree
Posts: 327
Joined: Tue Jun 30, 2015 12:58 am
Location: Bangkok Thailand

Re: ifc mapping

Post by chakkree »

Version: 0.18.13705+

IfcMapping.png
IfcMapping.png (578.58 KiB) Viewed 2161 times


---------------------------
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.13705 (Git)
Build type: Release
Branch: master
Hash: 891682a41220943af114f1312b57e04401c4cefb
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
Locale: English/UnitedStates (en_US)
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: ifc mapping

Post by bernd »

hardeeprai wrote: Wed May 09, 2018 12:19 am
Thank you.

Will go through, try to understand, and if there is any query, will come back.

In the mean time, if anyone has any suggestion, can give me some direction, pointer to other information available elsewhere, which could be useful.

I wanted to see "capacity of structural members" in ifc files. Is that possible?

I will calculate Moment carrying capacity of I-section used as beam or Reinforced Beam, and that should become property of structural member. Like wise a column will be having equivalent of P-M Load-Moment interaction Curve.
are you talking about StructuralAnalysisView (import supported by FreeCAD, https://github.com/berndhahnebach/Ifc_S ... alysisView ) or CoordinationView ( standard ifc import or export supported by FreeCAD) ?
User avatar
hardeeprai
Posts: 177
Joined: Sun May 23, 2010 2:41 pm
Location: Ludhiana, Punjab, India
Contact:

Re: ifc mapping

Post by hardeeprai »

bernd wrote: Wed May 16, 2018 8:24 pm are you talking about StructuralAnalysisView (import supported by FreeCAD, https://github.com/berndhahnebach/Ifc_S ... alysisView ) or CoordinationView ( standard ifc import or export supported by FreeCAD) ?
CoordinationView

Final outcome of structural analysis. What load a slab can take, so load carrying capacity (in UDL and/or concentrated load), how much load a beam or column can take. I mean, rated capacity of structural members.
--
H.S.Rai
Post Reply