mymesh.tree.getAllLeaf#

mymesh.tree.getAllLeaf(root, include_empty=False)[source]#

Retrieve a list of all leaf nodes of the tree

Parameters:
  • root (tree.TreeNode) – Root node of the tree of which the leaf nodes will be retrieved.

  • include_empty (bool, optional) – Option to include “empty” nodes in the set of leaves, by default False. “empty” nodes are terminal nodes that contain no data.

Returns:

leaves – List of tree leaf nodes.

Return type:

list