{
  "id": 225654,
  "title": "Quick observation about the dataset and Dice",
  "url": "/competitions/hubmap-kidney-segmentation/discussion/225654",
  "author_name": "",
  "post_date": "2021-03-13T09:22:41.675021200Z",
  "votes": 9,
  "comment_count": 3,
  "views": 0,
  "content": "<p>It seems like models that produce masks with smooth boundaries will be punished to some extent by the Dice metric. Here's a random example. The first image is the ground truth annotation, which is pretty great given it was created manually. The image on the right is the output of my model which is tracing along the boundary of the glomeruli.</p>\n<table>\n<thead>\n<tr>\n<th>Annotation</th>\n<th>Image</th>\n<th>Model Prediction</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><a href=\"https://postimg.cc/RWqvjvbW\" target=\"_blank\"><img src=\"https://i.postimg.cc/RWqvjvbW/annotation.png\" alt=\"annotation\"></a></td>\n<td><a href=\"https://postimg.cc/HrKTmFfB\" target=\"_blank\"><img src=\"https://i.postimg.cc/HrKTmFfB/image.png\" alt=\"image\"></a></td>\n<td><a href=\"https://postimg.cc/mcHBg84R\" target=\"_blank\"><img src=\"https://i.postimg.cc/mcHBg84R/prediction.png\" alt=\"prediction\"></a><br><br></td>\n</tr>\n</tbody>\n</table>",
  "messages": [
    {
      "id": "1236585",
      "postDate": "03/13/2021 09:22:41",
      "content": "<p>It seems like models that produce masks with smooth boundaries will be punished to some extent by the Dice metric. Here's a random example. The first image is the ground truth annotation, which is pretty great given it was created manually. The image on the right is the output of my model which is tracing along the boundary of the glomeruli.</p>\n<table>\n<thead>\n<tr>\n<th>Annotation</th>\n<th>Image</th>\n<th>Model Prediction</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><a href=\"https://postimg.cc/RWqvjvbW\" target=\"_blank\"><img src=\"https://i.postimg.cc/RWqvjvbW/annotation.png\" alt=\"annotation\"></a></td>\n<td><a href=\"https://postimg.cc/HrKTmFfB\" target=\"_blank\"><img src=\"https://i.postimg.cc/HrKTmFfB/image.png\" alt=\"image\"></a></td>\n<td><a href=\"https://postimg.cc/mcHBg84R\" target=\"_blank\"><img src=\"https://i.postimg.cc/mcHBg84R/prediction.png\" alt=\"prediction\"></a><br><br></td>\n</tr>\n</tbody>\n</table>",
      "rawMarkdown": "It seems like models that produce masks with smooth boundaries will be punished to some extent by the Dice metric. Here's a random example. The first image is the ground truth annotation, which is pretty great given it was created manually. The image on the right is the output of my model which is tracing along the boundary of the glomeruli.\n\n| Annotation | Image | Model Prediction |\n| --- | --- | --- |\n|<a href=\"https://postimg.cc/RWqvjvbW\" target=\"_blank\"><img src=\"https://i.postimg.cc/RWqvjvbW/annotation.png\" alt=\"annotation\"/></a>|<a href=\"https://postimg.cc/HrKTmFfB\" target=\"_blank\"><img src=\"https://i.postimg.cc/HrKTmFfB/image.png\" alt=\"image\"/></a>|<a href=\"https://postimg.cc/mcHBg84R\" target=\"_blank\"><img src=\"https://i.postimg.cc/mcHBg84R/prediction.png\" alt=\"prediction\"/></a><br/><br/>|",
      "votes": null
    },
    {
      "id": "1243916",
      "postDate": "03/18/2021 15:23:16",
      "content": "<p>Will the increase of threshold improve it? It seems that the area you predicted is a bit larger than GT.</p>",
      "rawMarkdown": "Will the increase of threshold improve it? It seems that the area you predicted is a bit larger than GT.",
      "votes": null
    },
    {
      "id": "1244234",
      "postDate": "03/18/2021 19:52:16",
      "content": "<p>how would that work?</p>",
      "rawMarkdown": "how would that work?",
      "votes": null
    },
    {
      "id": "1244245",
      "postDate": "03/18/2021 20:12:03",
      "content": "<p>The issue is that the annotations aren’t perfect. So if the model learns to trace exactly along the edge of the glomeruli, while  being correct, the prediction won’t match the annotations.</p>\n<p>Changing the threshold would help to minimize this but won’t fix it. Also I’m not using thresholds which has its own pros and cons.</p>",
      "rawMarkdown": "The issue is that the annotations aren’t perfect. So if the model learns to trace exactly along the edge of the glomeruli, while  being correct, the prediction won’t match the annotations.\n\nChanging the threshold would help to minimize this but won’t fix it. Also I’m not using thresholds which has its own pros and cons.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 1243916,
      "author_name": "louieshao",
      "author_url": "",
      "post_date": "03/18/2021 15:23:16",
      "content": "<p>Will the increase of threshold improve it? It seems that the area you predicted is a bit larger than GT.</p>",
      "votes": null,
      "replies": [
        {
          "id": 1244234,
          "author_name": "andrasferenczi",
          "author_url": "",
          "post_date": "03/18/2021 19:52:16",
          "content": "<p>how would that work?</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 1244245,
          "author_name": "erikdali",
          "author_url": "",
          "post_date": "03/18/2021 20:12:03",
          "content": "<p>The issue is that the annotations aren’t perfect. So if the model learns to trace exactly along the edge of the glomeruli, while  being correct, the prediction won’t match the annotations.</p>\n<p>Changing the threshold would help to minimize this but won’t fix it. Also I’m not using thresholds which has its own pros and cons.</p>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "1236585": "It seems like models that produce masks with smooth boundaries will be punished to some extent by the Dice metric. Here's a random example. The first image is the ground truth annotation, which is pretty great given it was created manually. The image on the right is the output of my model which is tracing along the boundary of the glomeruli.\n\n| Annotation | Image | Model Prediction |\n| --- | --- | --- |\n|<a href=\"https://postimg.cc/RWqvjvbW\" target=\"_blank\"><img src=\"https://i.postimg.cc/RWqvjvbW/annotation.png\" alt=\"annotation\"/></a>|<a href=\"https://postimg.cc/HrKTmFfB\" target=\"_blank\"><img src=\"https://i.postimg.cc/HrKTmFfB/image.png\" alt=\"image\"/></a>|<a href=\"https://postimg.cc/mcHBg84R\" target=\"_blank\"><img src=\"https://i.postimg.cc/mcHBg84R/prediction.png\" alt=\"prediction\"/></a><br/><br/>|",
    "1243916": "Will the increase of threshold improve it? It seems that the area you predicted is a bit larger than GT.",
    "1244234": "how would that work?",
    "1244245": "The issue is that the annotations aren’t perfect. So if the model learns to trace exactly along the edge of the glomeruli, while  being correct, the prediction won’t match the annotations.\n\nChanging the threshold would help to minimize this but won’t fix it. Also I’m not using thresholds which has its own pros and cons."
  },
  "source": "meta"
}