{
  "id": 314301,
  "title": "🐋 A small trick to improve score 🐬",
  "url": "/competitions/happy-whale-and-dolphin/discussion/314301",
  "author_name": "",
  "post_date": "2022-03-22T01:41:13.795538Z",
  "votes": 16,
  "comment_count": 6,
  "views": 0,
  "content": "<p>Since the data distribution is unbalanced, I used focal loss instead of cross entropy loss and achieved a small improvement in public scores.</p>\n<p>If you are interested, you can check my notebook.</p>\n<p><a href=\"https://www.kaggle.com/code/zeta1996/pytorch-lightning-arcface-focal-loss\" target=\"_blank\">https://www.kaggle.com/code/zeta1996/pytorch-lightning-arcface-focal-loss</a></p>",
  "messages": [
    {
      "id": "1731099",
      "postDate": "03/22/2022 01:41:13",
      "content": "<p>Since the data distribution is unbalanced, I used focal loss instead of cross entropy loss and achieved a small improvement in public scores.</p>\n<p>If you are interested, you can check my notebook.</p>\n<p><a href=\"https://www.kaggle.com/code/zeta1996/pytorch-lightning-arcface-focal-loss\" target=\"_blank\">https://www.kaggle.com/code/zeta1996/pytorch-lightning-arcface-focal-loss</a></p>",
      "rawMarkdown": "Since the data distribution is unbalanced, I used focal loss instead of cross entropy loss and achieved a small improvement in public scores.\n\nIf you are interested, you can check my notebook.\n\nhttps://www.kaggle.com/code/zeta1996/pytorch-lightning-arcface-focal-loss",
      "votes": null
    },
    {
      "id": "1731110",
      "postDate": "03/22/2022 02:04:42",
      "content": "<p>Great job!</p>",
      "rawMarkdown": "Great job!",
      "votes": null
    },
    {
      "id": "1732648",
      "postDate": "03/23/2022 15:33:09",
      "content": "<p>Fantastic technique, I shall definitely try it</p>",
      "rawMarkdown": "Fantastic technique, I shall definitely try it",
      "votes": null
    },
    {
      "id": "1734108",
      "postDate": "03/25/2022 01:34:00",
      "content": "<p>👍I've tried applying arcface loss with focal loss but didn't see improve.In the origin paper,the author said they believe there is no need to use arcface loss with other loss functions.Arcface loss is good enough.But it's still worth trying,isn't it?</p>",
      "rawMarkdown": "👍I've tried applying arcface loss with focal loss but didn't see improve.In the origin paper,the author said they believe there is no need to use arcface loss with other loss functions.Arcface loss is good enough.But it's still worth trying,isn't it?",
      "votes": null
    },
    {
      "id": "1734113",
      "postDate": "03/25/2022 01:55:33",
      "content": "<p>I also saw no improvement with focal loss, and I dont know if it work for basic classification task in this competition (I also see no improvement in this too, maybe my code is wrong @@). Anyway, its a good work (I dont know how it work though @), the more experiments we try, the more we learn, right? @@</p>",
      "rawMarkdown": "I also saw no improvement with focal loss, and I dont know if it work for basic classification task in this competition (I also see no improvement in this too, maybe my code is wrong @@). Anyway, its a good work (I dont know how it work though @), the more experiments we try, the more we learn, right? @@",
      "votes": null
    },
    {
      "id": "1736734",
      "postDate": "03/27/2022 16:57:01",
      "content": "<p>What about weighted sampler?</p>",
      "rawMarkdown": "What about weighted sampler?",
      "votes": null
    },
    {
      "id": "1736747",
      "postDate": "03/27/2022 17:02:39",
      "content": "<p>You can check my code. If it helps, vote for me.</p>",
      "rawMarkdown": "You can check my code. If it helps, vote for me.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 1731110,
      "author_name": "yangranran",
      "author_url": "",
      "post_date": "03/22/2022 02:04:42",
      "content": "<p>Great job!</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1732648,
      "author_name": "ravi20076",
      "author_url": "",
      "post_date": "03/23/2022 15:33:09",
      "content": "<p>Fantastic technique, I shall definitely try it</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1734108,
      "author_name": "jimmysmith1009",
      "author_url": "",
      "post_date": "03/25/2022 01:34:00",
      "content": "<p>👍I've tried applying arcface loss with focal loss but didn't see improve.In the origin paper,the author said they believe there is no need to use arcface loss with other loss functions.Arcface loss is good enough.But it's still worth trying,isn't it?</p>",
      "votes": null,
      "replies": [
        {
          "id": 1734113,
          "author_name": "dqhdqmcttdqx",
          "author_url": "",
          "post_date": "03/25/2022 01:55:33",
          "content": "<p>I also saw no improvement with focal loss, and I dont know if it work for basic classification task in this competition (I also see no improvement in this too, maybe my code is wrong @@). Anyway, its a good work (I dont know how it work though @), the more experiments we try, the more we learn, right? @@</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 1736734,
      "author_name": "jainishsavalia",
      "author_url": "",
      "post_date": "03/27/2022 16:57:01",
      "content": "<p>What about weighted sampler?</p>",
      "votes": null,
      "replies": [
        {
          "id": 1736747,
          "author_name": "zeta1996",
          "author_url": "",
          "post_date": "03/27/2022 17:02:39",
          "content": "<p>You can check my code. If it helps, vote for me.</p>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "1731099": "Since the data distribution is unbalanced, I used focal loss instead of cross entropy loss and achieved a small improvement in public scores.\n\nIf you are interested, you can check my notebook.\n\nhttps://www.kaggle.com/code/zeta1996/pytorch-lightning-arcface-focal-loss",
    "1731110": "Great job!",
    "1732648": "Fantastic technique, I shall definitely try it",
    "1734108": "👍I've tried applying arcface loss with focal loss but didn't see improve.In the origin paper,the author said they believe there is no need to use arcface loss with other loss functions.Arcface loss is good enough.But it's still worth trying,isn't it?",
    "1734113": "I also saw no improvement with focal loss, and I dont know if it work for basic classification task in this competition (I also see no improvement in this too, maybe my code is wrong @@). Anyway, its a good work (I dont know how it work though @), the more experiments we try, the more we learn, right? @@",
    "1736734": "What about weighted sampler?",
    "1736747": "You can check my code. If it helps, vote for me."
  },
  "source": "meta"
}