Github user yinxusen commented on a diff in the pull request:

    https://github.com/apache/spark/pull/11119#discussion_r83510194
  
    --- Diff: mllib/src/main/scala/org/apache/spark/ml/util/ReadWrite.scala ---
    @@ -300,15 +301,23 @@ private[ml] object DefaultParamsWriter {
           paramMap: Option[JValue] = None): String = {
         val uid = instance.uid
         val cls = instance.getClass.getName
    -    val params = 
instance.extractParamMap().toSeq.asInstanceOf[Seq[ParamPair[Any]]]
    +    val params = instance.extractParamMap().toSeq
    +      .filter(_.param.name != 
"initialModel").asInstanceOf[Seq[ParamPair[Any]]]
    --- End diff --
    
    I tried `_.isInsance[Param[Model[_]]]` and it failed because of the erasing 
of `Model[_]` in Java runtime.


---
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

Reply via email to