IFC

Forum per le domande e le discussioni in Italiano
Forum rules
regole del forum e le informazioni utili

Importante: PRIMA di chiedere aiuto leggete qui!
Ukacor
Posts: 128
Joined: Wed Mar 20, 2019 9:58 am
Location: Marche

IFC

Post by Ukacor »

Buongiorno a tutti,

sono un novizio di questo software ed ho solo seguito qualche video tutorial. Ho cercato l'argomento di cui vorrei chiedere delucidazioni ma non ho trovato nulla a riguardo a quanto mi pare di aver capito.

Sono un termotecnico e per professione di fatto mi è sufficiente il cad 2d per lavorare; tuttavia, i tempi evolvono per fortuna ed ormai nel mondo dell'edilizia si sta sempre più spesso lavorando con il BIM.

Ho un collega con il quale ho l'esigenza di interfacciarmi che lavora con l'architettonico usando Allplan. Io avrei pensato di poterci scambiare i files IFC che lui può esportare ed io potrei andarli a leggere con Freecad importandoli.
In Freecad io ho installato l'addon BIM ed ho fatto un test facendomi spedire un file di prova "Interrato_2019.ifc" che ho tentato di aprire.
Facendo "nuovo" e poi apri file, Il file lo apro, leggo nell'albero di Sx "Interrato_2019.ifc" ma non visualizzo niente nell'area grafica.

Manca una qualche parte software aggiuntiva per poter ottenere ciò che chiedo? Mi sembra di aver letto che serve IFC Open Shell e Vi chiedo se è confermato questo se c'è un qualche tutorial che aiuta alla sua installazione.

Vi ringrazio in anticipo.

Un saluto a tutti.


OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.16117 (Git)
Build type: Release
Branch: releases/FreeCAD-0-18
Hash: dbb4cc6415bac848a294f03b80f65e888d531742
Python version: 3.6.6
Qt version: 5.6.2
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: Italian/Italy (it_IT)
Attachments
INTERRATO_2019.ifc
(1016.8 KiB) Downloaded 47 times
renatorivo
Veteran
Posts: 2611
Joined: Tue Feb 21, 2012 8:07 pm
Location: Torino - Italy

Re: IFC

Post by renatorivo »

Controlla il tuo Report, a me viene l'errore indicato sotto e FreeCAD si blocca. Se a te succede la stessa cosa lo segnaliamo nel forum inglese.
errore ifc.PNG
errore ifc.PNG (26.21 KiB) Viewed 1523 times
Edit.
Il report sopra è con v0.19, con v0.18 invece non succede nulla e il report è
errore ifc018.PNG
errore ifc018.PNG (10.06 KiB) Viewed 1516 times
Ukacor
Posts: 128
Joined: Wed Mar 20, 2019 9:58 am
Location: Marche

Re: IFC

Post by Ukacor »

Grazie Renatorivo,

io nel report ho questo:

Python 3.6.6 | packaged by conda-forge | (default, Jul 26 2018, 11:48:23) [MSC v.1900 64 bit (AMD64)] on win32
Type 'help', 'copyright', 'credits' or 'license' for more information.
>>> Gui.activateWorkbench("BIMWorkbench")
>>> App.newDocument("Senza nome")
>>> App.setActiveDocument("Senza_nome")
>>> App.ActiveDocument=App.getDocument("Senza_nome")
>>> Gui.ActiveDocument=Gui.getDocument("Senza_nome")
>>> Gui.activeDocument().activeView().viewDefaultOrientation()
>>> App.closeDocument('Senza_nome')
>>> App.setActiveDocument("")
>>> App.ActiveDocument=None
>>> Gui.ActiveDocument=None
>>> import importIFC
>>> importIFC.open(u"D:/Download/FreeCAD/IFC/INTERRATO_2019.ifc")
>>> App.setActiveDocument("INTERRATO_2019")
>>> App.ActiveDocument=App.getDocument("INTERRATO_2019")
>>> Gui.ActiveDocument=Gui.getDocument("INTERRATO_2019")
>>> Gui.SendMsgToActiveView("ViewFit")
Ukacor
Posts: 128
Joined: Wed Mar 20, 2019 9:58 am
Location: Marche

Re: IFC

Post by Ukacor »

renatorivo wrote: Sat Nov 02, 2019 6:03 pm Controlla il tuo Report, a me viene l'errore indicato sotto e FreeCAD si blocca. Se a te succede la stessa cosa lo segnaliamo nel forum inglese.
errore ifc.PNG
Edit.
Il report sopra è con v0.19, con v0.18 invece non succede nulla e il report è
errore ifc018.PNG

Ho chiuso e riaperto Freecad. Ho aperto direttamente il file ed il report mi ha dato questo:

Python 3.6.6 | packaged by conda-forge | (default, Jul 26 2018, 11:48:23) [MSC v.1900 64 bit (AMD64)] on win32
Type 'help', 'copyright', 'credits' or 'license' for more information.
>>> import importIFC
>>> importIFC.open(u"D:/Download/FreeCAD/IFC/INTERRATO_2019.ifc")
>>> App.setActiveDocument("INTERRATO_2019")
>>> App.ActiveDocument=App.getDocument("INTERRATO_2019")
>>> Gui.ActiveDocument=Gui.getDocument("INTERRATO_2019")
>>> Gui.SendMsgToActiveView("ViewFit")
Ukacor
Posts: 128
Joined: Wed Mar 20, 2019 9:58 am
Location: Marche

Re: IFC

Post by Ukacor »

renatorivo wrote: Sat Nov 02, 2019 6:03 pm Controlla il tuo Report, a me viene l'errore indicato sotto e FreeCAD si blocca. Se a te succede la stessa cosa lo segnaliamo nel forum inglese.
errore ifc.PNG
Edit.
Il report sopra è con v0.19, con v0.18 invece non succede nulla e il report è
errore ifc018.PNG
Ti ho inviato il messaggio di Python!

Nel Report ho questo:

C:\Program Files\FreeCAD 0.18\bin\lib\site-packages\matplotlib\__init__.py:908: MatplotlibDeprecationWarning: The backend.qt4 rcParam was deprecated in version 2.2. In order to force the use of a specific Qt binding, either import that binding first, or set the QT_API environment variable.
mplDeprecation)
Finished importing.
renatorivo
Veteran
Posts: 2611
Joined: Tue Feb 21, 2012 8:07 pm
Location: Torino - Italy

Re: IFC

Post by renatorivo »

Dato che il problema si presenta anche con altri file ho segnalato in https://forum.freecadweb.org/viewtopic. ... 83#p345083
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: IFC

Post by bernd »

User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: IFC

Post by bernd »

sorry for answering in English. May be someone could translate ...

For some reason ifcopenshell does not find the IfcProject. The crash is fixed, but still nothing is imported.

This file was exported with Allplan. I have imported hundreds of Allplan ifs (but IFC2x3 not IFC4) without haveing this problem. Try to export from Allplan as IFC2x3 and not IFC4 is what I would try.

Code: Select all

import ifcopenshell
ifcfile = "C:/Users/BHA/Downloads/INTERRATO_2019.ifc"
f = ifcopenshell.open(ifcfile)
f.by_type('IfcProject')

Code: Select all

>>> 
>>> import ifcopenshell
>>> ifcfile = "C:/Users/BHA/Downloads/INTERRATO_2019.ifc"
>>> f = ifcopenshell.open(ifcfile)
>>> f.by_type('IfcProject')
[]
>>>
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: IFC

Post by bernd »

in Allplan use export to IFC (new Allplan exporter) and use IFC2x3. These files will be imported in FreeCAD. I will post in the other english topic more informations ...
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: IFC

Post by bernd »

solved ... see https://forum.freecadweb.org/viewtopic.php?f=39&t=40624

Screenshot_20191104_123722.png
Screenshot_20191104_123722.png (125.17 KiB) Viewed 1407 times
Post Reply