Adds get_tol_subtree function.