[
https://issues.apache.org/jira/browse/SPARK-3510?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Sean Owen resolved SPARK-3510.
------------------------------
Resolution: Not A Problem
> Create method for calculating error between expected result and actual
> ----------------------------------------------------------------------
>
> Key: SPARK-3510
> URL: https://issues.apache.org/jira/browse/SPARK-3510
> Project: Spark
> Issue Type: New Feature
> Components: MLlib
> Reporter: Egor Pakhomov
> Priority: Minor
>
> Could not do it right now, because zip operation need same number elements in
> partition, which I can not garantee.
> right now using next code:
> {code:title=Bar.scala|borderStyle=solid}
> val expectedRepartitioned = expected.cache().repartition(1) // need for
> zip operation
> val actualRepartitioned = actual.cache().repartition(1)
> new DoubleRDDFunctions(
> expectedRepartitioned
> .zip(actualRepartitioned)
> .map(a => {
> Math.pow(a._1 - a._2, 2)
> })).mean()
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]