Select Instances of a Revit IFC linked file

Hello everyone,

Im curently working on a project where i have to place MEP supports on structeral I-profiles. most structeral models are imported into Revit from a IFC model and are often linked models. These IFC Linked models dont have a lot of consitent parameters, for some projects the name of the elements are put in the Ifcname parameter, sometimes the ifcname parameters are empty. the same goes for many other parameters. i dont know how i can select all the I-profiles in a model when they dont have consistent parameters. does anyone have any suggestions?

@ThazenbergAFZXV

actually, when it is revit, just collect the linked ifc

i know f.e. from LINEAR - Software für Gebäudetechnik are all Entites are GenericModells

so you can collect them, here a revit ifc export test

import clr
import sys 

clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
from Autodesk.Revit.DB.Structure import *

clr.AddReference('RevitAPIUI')
from Autodesk.Revit.UI import *

clr.AddReference('System')
from System.Collections.Generic import List

clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
clr.ImportExtensions(Revit.Elements)

clr.AddReference('RevitServices')
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

doc = DocumentManager.Instance.CurrentDBDocument
uidoc=DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument

#🌈 links
linked_docs = FilteredElementCollector(doc).OfCategory(BuiltInCategory.OST_RvtLinks).WhereElementIsNotElementType().ToElements()
lnkInstance = [i for i in linked_docs if i.Name.Contains(".ifc")]
doclnk = lnkInstance[0].GetLinkDocument()

# 🎯 collect hydrants from linked file
hydrants = FilteredElementCollector(doclnk, doc.ActiveView.Id).OfCategory(BuiltInCategory.OST_PlumbingFixtures).WhereElementIsNotElementType().ToElements()

OUT = hydrants

Thanks for the reply, Im not very experienced with Python scripts. How can i change the scripts so it filters out I-profile standers?

@ThazenbergAFZXV ,

there are a lot of ways

you can use groupByKey
or String.Contains

and filter them out, there are plenty examples here in the forum.