[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user mengxr commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68843064 @viirya They are the same analytically but not numerically, for example, ~~~scala scala math.log1p(math.exp(1000)) res2: Double = Infinity scala 1000 + math.log1p(math.exp(-1000)) res3: Double = 1000.0 ~~~ --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user viirya commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68846927 OK. I understood it. I am wrong for LogLoss. Will revert it back. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user viirya commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68847701 @mengxr @srowen New commit shoud make the computation more accurate. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68847888 [Test build #25097 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25097/consoleFull) for PR 3899 at commit [`72a295e`](https://github.com/apache/spark/commit/72a295eed4ca4dd6d70aeb11a7246d4558bdd8c9). * This patch merges cleanly. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user viirya commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68848217 @mengxr I noticed that you file a issue in [#SPARK-5101](https://issues.apache.org/jira/browse/SPARK-5101). Do I need to extract the codes in this pr to the place you suggested `mllib.util.MathFunctions`? --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68842795 [Test build #25093 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25093/consoleFull) for PR 3899 at commit [`a3f83ca`](https://github.com/apache/spark/commit/a3f83ca41c70fd212e335c03bf213b1c171dca9a). * This patch **passes all tests**. * This patch merges cleanly. * This patch adds no public classes. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68842807 Test PASSed. Refer to this link for build results (access rights to CI server needed): https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/25093/ Test PASSed. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68854264 Test PASSed. Refer to this link for build results (access rights to CI server needed): https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/25097/ Test PASSed. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68854259 [Test build #25097 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25097/consoleFull) for PR 3899 at commit [`72a295e`](https://github.com/apache/spark/commit/72a295eed4ca4dd6d70aeb11a7246d4558bdd8c9). * This patch **passes all tests**. * This patch merges cleanly. * This patch adds no public classes. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68864131 [Test build #25101 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25101/consoleFull) for PR 3899 at commit [`0aa51e4`](https://github.com/apache/spark/commit/0aa51e483224bae746d4e8b604b12e405899a9df). * This patch merges cleanly. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user viirya commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68864189 @mengxr I think I already know what you meant to branch based on `sign(label * margin)`. I made some modifications. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68871848 [Test build #25101 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25101/consoleFull) for PR 3899 at commit [`0aa51e4`](https://github.com/apache/spark/commit/0aa51e483224bae746d4e8b604b12e405899a9df). * This patch **passes all tests**. * This patch merges cleanly. * This patch adds no public classes. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68871860 Test PASSed. Refer to this link for build results (access rights to CI server needed): https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/25101/ Test PASSed. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user jkbradley commented on a diff in the pull request: https://github.com/apache/spark/pull/3899#discussion_r22549295 --- Diff: mllib/src/main/scala/org/apache/spark/mllib/optimization/Gradient.scala --- @@ -64,11 +64,17 @@ class LogisticGradient extends Gradient { val gradientMultiplier = (1.0 / (1.0 + math.exp(margin))) - label val gradient = data.copy scal(gradientMultiplier, gradient) +val minusYP = label * margin --- End diff -- This looks like you expect labels to be -1, +1. They are actually 0, 1. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user viirya commented on a diff in the pull request: https://github.com/apache/spark/pull/3899#discussion_r22567347 --- Diff: mllib/src/main/scala/org/apache/spark/mllib/optimization/Gradient.scala --- @@ -64,11 +64,17 @@ class LogisticGradient extends Gradient { val gradientMultiplier = (1.0 / (1.0 + math.exp(margin))) - label val gradient = data.copy scal(gradientMultiplier, gradient) +val minusYP = label * margin --- End diff -- Oh? I thought it is similar to LogLoss so it would be {+1, -1}. Fixed. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68968909 [Test build #25127 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25127/consoleFull) for PR 3899 at commit [`91a3860`](https://github.com/apache/spark/commit/91a3860125d9f7d2e4a87dfe5a9795c18ca76c53). * This patch merges cleanly. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user SparkQA commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68973934 [Test build #25127 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/25127/consoleFull) for PR 3899 at commit [`91a3860`](https://github.com/apache/spark/commit/91a3860125d9f7d2e4a87dfe5a9795c18ca76c53). * This patch **passes all tests**. * This patch merges cleanly. * This patch adds no public classes. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user mengxr commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68971483 LGTM pending Jenkins. I'm going to merge this first. We might want to add more functions in #3915 . --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user viirya commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68979842 Thanks. --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user mengxr commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68980441 Merged into master. Thanks! --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user asfgit closed the pull request at: https://github.com/apache/spark/pull/3899 --- 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
[GitHub] spark pull request: [SPARK-5099][Mllib] Simplify logistic loss fun...
Github user AmplabJenkins commented on the pull request: https://github.com/apache/spark/pull/3899#issuecomment-68973938 Test PASSed. Refer to this link for build results (access rights to CI server needed): https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/25127/ Test PASSed. --- 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