OSArch Community

New IFC facet-based selector syntax

  1. B

    solved one of the two problems ...

    @bernd said:

    A property name does have a Space inside. I am not able to filterfor this property values ...

    query = "IfcWall, Architekt.'Tragendes Bauteil'=/^FALSE/"

    it has to be

    query = 'IfcWall, Allreal."Tragendes Bauteil"=/^FALSE/'

  2. B

    noone out here a idea if it is not implemented or if I do some mistake ...

    @bernd said:

    next problem to solve ...

    "material" filters Materials, "Name" filters by Name ...

    What do I need to filter Layer ? I tried "Layer" and "layer" but both did not return something reasonable ...

    from IFC ...

    #113754=IFCPRESENTATIONLAYERASSIGNMENT('115 Liftanlagen.002',$,(#25008,#25402,#25403,#25404,#25405,#25406,#25407),$);

  3. T

    Maybe...

  4. S

    @theoryshaw said:

    Maybe...

    thanks, I meant to add yours to my query examples but, what is a practical use of layer in Bonsai? the same as in DWG? cheers

  5. T

    Yes, as i understand it, it's kinda like that. I don't use it, however.

  6. B

    Just got the model seen in the screen from an landscape architect. 180 MB but probably 95% data volumes are trees which I do not need at all ... Let BBIM help myself to get something to easily work with ...

    First idea:

    Open the file in BBIM and delete the trees works fine, but takes two hours on my machanine. But BBIM did not crash :-) But there must be a better way ... Actually there is ...

    Second idea, use the filter and IfcPatch

    Start by finding the correct filter by python ...

    from ifcopenshell.util import selector
    
    query = "IfcBuildingElement"
    
    len(ifcopenshell.util.selector.filter_elements(ifcfile, query))
    
    query = "IfcBuildingElement, Name!=/^Platane/, Name!=/^Bush/, Name!=/^Willow/, Name!=/^Black_Maple/, Name!=/^Nordmann/, Name!=/^Elm_Tree/, Name!=/^Chestnut_Tree/"
    
    len(ifcopenshell.util.selector.filter_elements(ifcfile, query))

    results in:

    >>> 
    
    >>> from ifcopenshell.util import selector
    
    >>> query = "IfcBuildingElement"
    
    >>> len(ifcopenshell.util.selector.filter_elements(ifcfile, query))
    
    724
    
    >>> query = "IfcBuildingElement, Name!=/^Platane/, Name!=/^Bush/, Name!=/^Willow/, Name!=/^Black_Maple/, Name!=/^Nordmann/, Name!=/^Elm_Tree/, Name!=/^Chestnut_Tree/"
    
    >>> len(ifcopenshell.util.selector.filter_elements(ifcfile, query))
    
    576
    
    >>> 

    Since it seams to work fine, use IfcPatch tool from BBIM Gui with the query from above:

    IfcBuildingElement, Name!=/^Platane/, Name!=/^Bush/, Name!=/^Willow/, Name!=/^Black_Maple/, Name!=/^Nordmann/, Name!=/^Elm_Tree/, Name!=/^Chestnut_Tree/

    takes just 10 minutes all together and results in a ifc of around 11.4 MB ... :-) More than 10 times faster than open the file in BBBIM Gui, deleting the elems and save the file and much more robust.

  7. O

    Good evening. How do I exclude IfcAnnotation[GRID] from my drawings when I create them. All efforts are not yielding results.

    Thank you.

  8. T

    Exclude: IfcAnnotation, ObjectType = GRID

  9. O

    @theoryshaw said:

    Exclude: IfcAnnotation, ObjectType = GRID

    Thank you very much.

  1. Page 1
  2. 2
  3. 3
  4. 4
  5. 5

Login or Register to reply.