Skip to content
Snippets Groups Projects
  • Zheng RuiFeng's avatar
    47a2940d
    [SPARK-15398][ML] Update the warning message to recommend ML usage · 47a2940d
    Zheng RuiFeng authored
    ## What changes were proposed in this pull request?
    MLlib are not recommended to use, and some methods are even deprecated.
    Update the warning message to recommend ML usage.
    ```
      def showWarning() {
        System.err.println(
          """WARN: This is a naive implementation of Logistic Regression and is given as an example!
            |Please use either org.apache.spark.mllib.classification.LogisticRegressionWithSGD or
            |org.apache.spark.mllib.classification.LogisticRegressionWithLBFGS
            |for more conventional use.
          """.stripMargin)
      }
    ```
    To
    ```
      def showWarning() {
        System.err.println(
          """WARN: This is a naive implementation of Logistic Regression and is given as an example!
            |Please use org.apache.spark.ml.classification.LogisticRegression
            |for more conventional use.
          """.stripMargin)
      }
    ```
    
    ## How was this patch tested?
    local build
    
    Author: Zheng RuiFeng <ruifengz@foxmail.com>
    
    Closes #13190 from zhengruifeng/update_recd.
    47a2940d
    History
    [SPARK-15398][ML] Update the warning message to recommend ML usage
    Zheng RuiFeng authored
    ## What changes were proposed in this pull request?
    MLlib are not recommended to use, and some methods are even deprecated.
    Update the warning message to recommend ML usage.
    ```
      def showWarning() {
        System.err.println(
          """WARN: This is a naive implementation of Logistic Regression and is given as an example!
            |Please use either org.apache.spark.mllib.classification.LogisticRegressionWithSGD or
            |org.apache.spark.mllib.classification.LogisticRegressionWithLBFGS
            |for more conventional use.
          """.stripMargin)
      }
    ```
    To
    ```
      def showWarning() {
        System.err.println(
          """WARN: This is a naive implementation of Logistic Regression and is given as an example!
            |Please use org.apache.spark.ml.classification.LogisticRegression
            |for more conventional use.
          """.stripMargin)
      }
    ```
    
    ## How was this patch tested?
    local build
    
    Author: Zheng RuiFeng <ruifengz@foxmail.com>
    
    Closes #13190 from zhengruifeng/update_recd.