[ https://issues.apache.org/jira/browse/SPARK-11507?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kareem Alhazred updated SPARK-11507: ------------------------------------ Description: In certain situations when adding two block matrices, I get an error regarding colPtr and the operation fails. External issue URL includes full error and code for reproducing the problem. was: In certain situations when adding two block matrices, I get an error regarding colPtr and the operation fails. Please see code below for a representative example. External issue URL also includes full error message. import org.apache.spark.mllib.linalg._ import org.apache.spark.mllib.linalg.distributed._ import org.apache.spark.{SparkConf, SparkContext} object runAddBug { def main(args: Array[String]) { val appName = "addbug" val conf = new SparkConf().setAppName(appName) val sc = new SparkContext(conf) val N = 200 val Nbx = 10 val diags = sc.parallelize(0 to N-1) val Eyecm = new CoordinateMatrix(diags.map{d => MatrixEntry(d, d, 1.0)}, N, N) val diagsq = diags.cartesian(diags) val Bcm = new CoordinateMatrix(diagsq.map{dd => MatrixEntry( dd._1, dd._2, 1.0*dd._1*dd._2)}, N, N) val Rpb = (N/Nbx).toInt val Cpb = (N/Nbx).toInt var A = Eyecm.toBlockMatrix(Rpb,Cpb) var B = Bcm.toBlockMatrix(Rpb,Cpb) var C = A.add(B) val entsOut = C.toCoordinateMatrix().entries val outLines = entsOut.map{anent => anent.i.toString + "\t" + anent.j.toString + "\t" + anent.value.toString } outLines.saveAsTextFile("Outdata") } } > Error thrown when using BlockMatrix.add > --------------------------------------- > > Key: SPARK-11507 > URL: https://issues.apache.org/jira/browse/SPARK-11507 > Project: Spark > Issue Type: Bug > Components: MLlib > Affects Versions: 1.3.1, 1.5.0 > Environment: Mac/local machine, EC2 > Scala > Reporter: Kareem Alhazred > Priority: Minor > > In certain situations when adding two block matrices, I get an error > regarding colPtr and the operation fails. External issue URL includes full > error and code for reproducing the problem. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org