[ https://issues.apache.org/jira/browse/SPARK-13066?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15122503#comment-15122503 ]
Seth Hendrickson commented on SPARK-13066: ------------------------------------------ Posted this on a [previous PR|https://github.com/apache/spark/pull/9581#issuecomment-176473073], but re-posting here as it is more current: I am thinking about how we can avoid getting {{java.lang.ClassCastException}} when passing incorrect Param types through to Scala. Is there any reason we cannot make {{expectedType}} a required argument? Then we set it if the type equals expected type, and try to convert it if not. If it cannot be converted then we raise an exception. It would be nice to avoid users getting somewhat cryptic, non-intuitive py4j errors. Thoughts? > Specify types for per-model/estimator params in ML to allow automatic type > conversion > ------------------------------------------------------------------------------------- > > Key: SPARK-13066 > URL: https://issues.apache.org/jira/browse/SPARK-13066 > Project: Spark > Issue Type: Improvement > Components: ML, PySpark > Reporter: holdenk > Priority: Minor > > Specify types for per-model/estimator params in the same format as done for > generate params in SPARK-7675 now that SPARK-10509 is merged in and we won't > need to duplicate it everywhere. > cc [~sethah] who chatted with about this -- 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