code: def test_depth():
      """test the depth_from_leaves() methods"""
      f = simple_forest()
      depth = f.depth_from_leaves()
      assert depth[0] == 0
      assert depth[1] == 0
      assert depth[3] == 0
      assert depth[2] == 1
      assert depth[4] == 2
  
file_path: nipy/nipy/algorithms/graph/tests/test_forest.py
imports: import numpy
  from ..forest import Forest
label_desc: Use image node_id 9 for calling a global function with example usage: test_depth() without return types