Home > other >  How to use the spark to realize such a calculation
How to use the spark to realize such a calculation

Time:09-24

How to use the Spark to do such a thing, is calculated for each line of data, the calculation results of three matrix, the three matrix accumulation to the global three matrix, finally return to the three matrix,

Such as data
X1, x2, x3, x4,... X300, y
1, 3, 4, 5,... , 3, 1
2, 2, 4, 6,... , 4, 3
.

For each line, I calculate the transpose vector x x x, get M1 matrix, add it to the global GlobalM1, count me in the same way the second matrix y * y, accumulate in the global variable GlobalM2, the third one is a matrix vector x, y also accumulate in the global variable GlobalM3,

Thank you all!

CodePudding user response:


I'm sorry, because of my personal ability is limited, can't help you, sorry



CodePudding user response:

Ok, thank you

CodePudding user response:

Can you explain why calculation, will there be other calculations?
  • Related