First time here? Check out the FAQ!
answered 2016-10-17 03:43:57 -0600
you can use per-element multiplication for the square, like this:
Mat destSquared = destination.mul(destination);
then get the sum
Scalar s = Core.sumElems (destSquared); double sum = s[0]; // 1st channel