You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Vyacheslav Baranov (JIRA)" <ji...@apache.org> on 2015/08/24 14:45:45 UTC

[jira] [Created] (SPARK-10182) GeneralizedLinearModel doesn't unpersist cached data

Vyacheslav Baranov created SPARK-10182:
------------------------------------------

             Summary: GeneralizedLinearModel doesn't unpersist cached data
                 Key: SPARK-10182
                 URL: https://issues.apache.org/jira/browse/SPARK-10182
             Project: Spark
          Issue Type: Bug
          Components: MLlib
    Affects Versions: 1.4.1
            Reporter: Vyacheslav Baranov


The problem might be reproduced in spark-shell with following code snippet:

{code}
import org.apache.spark.SparkContext
import org.apache.spark.mllib.classification.LogisticRegressionWithLBFGS
import org.apache.spark.mllib.linalg.Vectors
import org.apache.spark.mllib.regression.LabeledPoint

val samples = Seq[LabeledPoint](
  LabeledPoint(1.0, Vectors.dense(1.0, 0.0)),
  LabeledPoint(1.0, Vectors.dense(0.0, 1.0)),
  LabeledPoint(0.0, Vectors.dense(1.0, 1.0)),
  LabeledPoint(0.0, Vectors.dense(0.0, 0.0))
)

val rdd = sc.parallelize(samples)

for (i <- 0 until 10) {
  val model = {
    new LogisticRegressionWithLBFGS()
      .setNumClasses(2)
      .run(rdd)
      .clearThreshold()
  }
}
{code}

After code execution there are 10 {{MapPartitionsRDD}} objects.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org