pedarProbe.analyse.attribute_average_up#

pedarProbe.analyse.attribute_average_up(node: Type[pedarnode.PedarNode], attr_name: str = 'sensor_peak', attr_func: function = <function sensor_peak>)[source]#

Recursively compute the attribute for each leaf node and then average it up as the upper node’s attribute layer by layer, towards root node level. The added attribute will be added to PedarNode’s attributes dictionary.

Parameters:
  • node – root node of the node tree.

  • attr_name – attribute name. Also as the keyword of the added item to self.attributes dictionary.

  • attr_func – attribute calculation function for leaf node.