model: add TreeNode debugging information to print_trace()