Create Minimum Depth of Binary Tree (pyemma)