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

    https://github.com/apache/spark/pull/10268#discussion_r47742030
  
    --- Diff: python/pyspark/ml/tuning.py ---
    @@ -106,7 +107,7 @@ class CrossValidator(Estimator):
         >>> lr = LogisticRegression()
         >>> grid = ParamGridBuilder().addGrid(lr.maxIter, [0, 1]).build()
         >>> evaluator = BinaryClassificationEvaluator()
    -    >>> cv = CrossValidator(estimator=lr, estimatorParamMaps=grid, 
evaluator=evaluator)
    +    >>> cv = CrossValidator(estimator=lr, estimatorParamMaps=grid, 
evaluator=evaluator, seed=42)
    --- End diff --
    
    We set default value of ```seed``` to 
[```this.getClass.getName.hashCode.toLong```](https://github.com/apache/spark/blob/master/mllib/src/main/scala/org/apache/spark/ml/param/shared/sharedParams.scala#L295)
 at Scala side. I think we should keep consistent with that, otherwise users 
may get different result when training with the same dataset.


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

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

Reply via email to