speeding up the inspect by creating the tree in memory