Changed update to gather all accumulators from leaf nodes, rather than calculate based on child nodes.