zhengruifeng commented on a change in pull request #33710:
URL: https://github.com/apache/spark/pull/33710#discussion_r702544438



##########
File path: 
mllib/src/main/scala/org/apache/spark/ml/classification/LogisticRegression.scala
##########
@@ -486,7 +486,8 @@ class LogisticRegression @Since("1.2.0") (
 
   private var optInitialModel: Option[LogisticRegressionModel] = None
 
-  private[spark] def setInitialModel(model: LogisticRegressionModel): 
this.type = {
+  @Since("3.3.0")
+  def setInitialModel(model: LogisticRegressionModel): this.type = {

Review comment:
       Since `model` is not a `Param`, I think we need to document this 
difference from other params:
   1, `model` is not saved in `MLWritable.save`;
   2, `model` is not passed to the trained model `LogisticRegressionModel`
   
   one case is:
   ```
   val lr = new LogisticRegression().setMaxIter(100).setInitialModel(otherModel)
   lr.save("/tmp/lr")                                           // does not 
save initial model
   val lr2 = LogisticRegression.load("/tmp/lr")  // does not contains model
   ```
   
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to