Skip to content

johltn/IfcGraph

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

IfcGraph

Use Networkx to manipulate an IFC file as a directed graph.

#graph.py

import ifcopenshell
import ifcgraph
import sys

fn = sys.argv[1]
ifc_file = ifcopenshell.open(fn)

G = ifcgraph.create_graph(ifc_file)  
sorted = list(reversed(list(nx.topological_sort(G))))
      
SG = ifcgraph.get_subgraph(23946, G)

ifcgraph.draw_graph(SG)

python graph.py input.ifc

Output:

image

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages