Annotates treepredict.py [chapter 7]