individually number each branch
jsonic version of tree.data.py