Github user srowen commented on a diff in the pull request: https://github.com/apache/spark/pull/8395#discussion_r37808640 --- Diff: mllib/src/main/scala/org/apache/spark/mllib/regression/GeneralizedLinearAlgorithm.scala --- @@ -287,7 +282,7 @@ abstract class GeneralizedLinearAlgorithm[M <: GeneralizedLinearModel] if (useFeatureScaling) { input.map(lp => (lp.label, scaler.transform(lp.features))).cache() } else { - input.map(lp => (lp.label, lp.features)) + input.map(lp => (lp.label, lp.features)).cache() --- End diff -- That makes sense too. I suppose changing behavior less is good. Yes, then the safer thing is to just unpersist only if the `data` RDD is persisted.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org