{
  "id": 95612,
  "title": "Evaluation metric",
  "url": "/competitions/champs-scalar-coupling/discussion/95612",
  "author_name": "",
  "post_date": "2019-06-13T14:51:00.615704300Z",
  "votes": 1,
  "comment_count": 4,
  "views": 0,
  "content": "<p>Hey folks, does anyone mind elaborating on what the <strong>Log</strong> of the <strong>mean absolute error</strong> is aimed at achieving/ <em>(what it's puporse is)</em>. It doesn't seem to be so clear to me so i would appreciate your responses. thanks</p>",
  "messages": [
    {
      "id": "552138",
      "postDate": "06/13/2019 14:51:00",
      "content": "<p>Hey folks, does anyone mind elaborating on what the <strong>Log</strong> of the <strong>mean absolute error</strong> is aimed at achieving/ <em>(what it's puporse is)</em>. It doesn't seem to be so clear to me so i would appreciate your responses. thanks</p>",
      "rawMarkdown": "Hey folks, does anyone mind elaborating on what the **Log** of the **mean absolute error** is aimed at achieving/ *(what it's puporse is)*. It doesn't seem to be so clear to me so i would appreciate your responses. thanks",
      "votes": null
    },
    {
      "id": "552190",
      "postDate": "06/13/2019 15:53:27",
      "content": "<p>There are eight types of coupling between atoms, and the amount of training data for each type varies a lot, ranging from over 1 million to just 40k. Using the group log MAE means that each group's MAE contributes the same, and you cannot strategically give up a group.</p>\n\n<p>For example, in the testing, if group 1 has 10 samples, with MAE = 1, group 2 has 1 sample, with MAE 10. Then the total MAE is 20/11 approximately = 1.8, which is much closer to group 1's MAE than group 2's MAE. </p>\n\n<p>Now using group log MAE, group 1's log MAE is 0, group 2's log MAE is about 2.3, the mean is 1.15, which is equidistant to group 1 and group 2's log MAEs, i.e., the final score is equally affected by each group, no matter how small that group is.</p>",
      "rawMarkdown": "There are eight types of coupling between atoms, and the amount of training data for each type varies a lot, ranging from over 1 million to just 40k. Using the group log MAE means that each group's MAE contributes the same, and you cannot strategically give up a group.\n\nFor example, in the testing, if group 1 has 10 samples, with MAE = 1, group 2 has 1 sample, with MAE 10. Then the total MAE is 20/11 approximately = 1.8, which is much closer to group 1's MAE than group 2's MAE. \n\nNow using group log MAE, group 1's log MAE is 0, group 2's log MAE is about 2.3, the mean is 1.15, which is equidistant to group 1 and group 2's log MAEs, i.e., the final score is equally affected by each group, no matter how small that group is.",
      "votes": null
    },
    {
      "id": "552766",
      "postDate": "06/14/2019 13:53:45",
      "content": "<p>Thanks a bunch <a href=\"/scaomath\">@scaomath</a> </p>",
      "rawMarkdown": "Thanks a bunch @scaomath",
      "votes": null
    },
    {
      "id": "570400",
      "postDate": "07/08/2019 08:31:56",
      "content": "<p><a href=\"/scaomath\">@scaomath</a> thanks for the explanation!  After reading your comment, it's very clear to see how the type-based log MAE computation balances the contribution of 8 types regardless of their size.  </p>\n\n<p>But I wonder if you or anyone else have the problem when using less precise type (say float32) when computing log MAE. \nI found that if I use float32 to compute MAE, it often result in zero difference and a \"inf\" when passing into log function. In other words, I need float64 to avoid the problem.  I just wonder if this is necessary. Thanks.! </p>",
      "rawMarkdown": "scaomath thanks for the explanation!  After reading your comment, it's very clear to see how the type-based log MAE computation balances the contribution of 8 types regardless of their size.  \n\nBut I wonder if you or anyone else have the problem when using less precise type (say float32) when computing log MAE. \nI found that if I use float32 to compute MAE, it often result in zero difference and a \"inf\" when passing into log function. In other words, I need float64 to avoid the problem.  I just wonder if this is necessary. Thanks.!",
      "votes": null
    },
    {
      "id": "570406",
      "postDate": "07/08/2019 08:38:08",
      "content": "<p>Hi <a href=\"/renewang\">@renewang</a> </p>\n\n<p>That's why they mention a floor of 1e-9 in the metric, see <a href=\"https://www.kaggle.com/uberkinder/efficient-metric\">this kernel</a> for an implementation.</p>\n\n<p>This should stop you from trying to compute log(0)</p>",
      "rawMarkdown": "Hi @renewang \n\nThat's why they mention a floor of 1e-9 in the metric, see [this kernel](https://www.kaggle.com/uberkinder/efficient-metric) for an implementation.\n\nThis should stop you from trying to compute log(0)",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 552190,
      "author_name": "scaomath",
      "author_url": "",
      "post_date": "06/13/2019 15:53:27",
      "content": "<p>There are eight types of coupling between atoms, and the amount of training data for each type varies a lot, ranging from over 1 million to just 40k. Using the group log MAE means that each group's MAE contributes the same, and you cannot strategically give up a group.</p>\n\n<p>For example, in the testing, if group 1 has 10 samples, with MAE = 1, group 2 has 1 sample, with MAE 10. Then the total MAE is 20/11 approximately = 1.8, which is much closer to group 1's MAE than group 2's MAE. </p>\n\n<p>Now using group log MAE, group 1's log MAE is 0, group 2's log MAE is about 2.3, the mean is 1.15, which is equidistant to group 1 and group 2's log MAEs, i.e., the final score is equally affected by each group, no matter how small that group is.</p>",
      "votes": null,
      "replies": [
        {
          "id": 552766,
          "author_name": "stephenmugisha",
          "author_url": "",
          "post_date": "06/14/2019 13:53:45",
          "content": "<p>Thanks a bunch <a href=\"/scaomath\">@scaomath</a> </p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 570400,
          "author_name": "renewang",
          "author_url": "",
          "post_date": "07/08/2019 08:31:56",
          "content": "<p><a href=\"/scaomath\">@scaomath</a> thanks for the explanation!  After reading your comment, it's very clear to see how the type-based log MAE computation balances the contribution of 8 types regardless of their size.  </p>\n\n<p>But I wonder if you or anyone else have the problem when using less precise type (say float32) when computing log MAE. \nI found that if I use float32 to compute MAE, it often result in zero difference and a \"inf\" when passing into log function. In other words, I need float64 to avoid the problem.  I just wonder if this is necessary. Thanks.! </p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 570406,
          "author_name": "fnands",
          "author_url": "",
          "post_date": "07/08/2019 08:38:08",
          "content": "<p>Hi <a href=\"/renewang\">@renewang</a> </p>\n\n<p>That's why they mention a floor of 1e-9 in the metric, see <a href=\"https://www.kaggle.com/uberkinder/efficient-metric\">this kernel</a> for an implementation.</p>\n\n<p>This should stop you from trying to compute log(0)</p>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "552138": "Hey folks, does anyone mind elaborating on what the **Log** of the **mean absolute error** is aimed at achieving/ *(what it's puporse is)*. It doesn't seem to be so clear to me so i would appreciate your responses. thanks",
    "552190": "There are eight types of coupling between atoms, and the amount of training data for each type varies a lot, ranging from over 1 million to just 40k. Using the group log MAE means that each group's MAE contributes the same, and you cannot strategically give up a group.\n\nFor example, in the testing, if group 1 has 10 samples, with MAE = 1, group 2 has 1 sample, with MAE 10. Then the total MAE is 20/11 approximately = 1.8, which is much closer to group 1's MAE than group 2's MAE. \n\nNow using group log MAE, group 1's log MAE is 0, group 2's log MAE is about 2.3, the mean is 1.15, which is equidistant to group 1 and group 2's log MAEs, i.e., the final score is equally affected by each group, no matter how small that group is.",
    "552766": "Thanks a bunch @scaomath",
    "570400": "scaomath thanks for the explanation!  After reading your comment, it's very clear to see how the type-based log MAE computation balances the contribution of 8 types regardless of their size.  \n\nBut I wonder if you or anyone else have the problem when using less precise type (say float32) when computing log MAE. \nI found that if I use float32 to compute MAE, it often result in zero difference and a \"inf\" when passing into log function. In other words, I need float64 to avoid the problem.  I just wonder if this is necessary. Thanks.!",
    "570406": "Hi @renewang \n\nThat's why they mention a floor of 1e-9 in the metric, see [this kernel](https://www.kaggle.com/uberkinder/efficient-metric) for an implementation.\n\nThis should stop you from trying to compute log(0)"
  },
  "source": "meta"
}