spark-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mengxr <>
Subject [GitHub] spark pull request: [SPARK-14050][ML] Add multiple languages suppo...
Date Tue, 22 Mar 2016 04:44:55 GMT
Github user mengxr commented on a diff in the pull request:
    --- Diff: mllib/src/main/scala/org/apache/spark/ml/feature/StopWordsRemover.scala ---
    @@ -98,13 +67,16 @@ class StopWordsRemover(override val uid: String)
        * the stop words set to be filtered out
    -   * Default: [[StopWords.English]]
    +   * Default: [[StopWords.languageMap("english")]]
        * @group param
       val stopWords: StringArrayParam = new StringArrayParam(this, "stopWords", "stop words")
       /** @group setParam */
    -  def setStopWords(value: Array[String]): this.type = set(stopWords, value)
    +  def setStopWords(value: Array[String]): this.type = {
    +    set(stopWords, value)
    +    set(language, "unknown")
    --- End diff --
    We shouldn't set other parameters in the setters since their are other ways to overwrite
param values. Let's keep the default language to `english` and if `stopWords` is set, ignore
the language setting. This logic should happen in `transform`.

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

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message