JDK

Optimize the average operation if the pipeline is sized