{
  "id": 544750,
  "title": "F-beta vs. F1 Score",
  "url": "/competitions/czii-cryo-et-object-identification/discussion/544750",
  "author_name": "",
  "post_date": "2024-11-06T22:43:27.164244200Z",
  "votes": 20,
  "comment_count": 1,
  "views": 0,
  "content": "<p>Just an FYI.  The general equation for the F-beta score is:</p>\n<p>$$F_{\\beta} = (1 + \\beta^2) \\cdot \\frac{precision \\cdot recall}{(\\beta^2 \\cdot precision) + recall}$$</p>\n<p>So if you're familiar with F1 Score it's just F-beta with beta = 1.</p>\n<p>$$F_{1} = 2 \\cdot \\frac{precision \\cdot recall}{precision + recall}$$</p>\n<p>For this competition, we use beta = 4:</p>\n<p>$$F_{4} = 17 \\cdot \\frac{precision \\cdot recall}{16 \\cdot precision + recall}$$</p>\n<p>Plugging in values of 0.8 for precision and 0.9 for recall gives an F4 score of 0.893.  Swapping the values gives an F4 score of 0.805 so you can see that recall is indeed weighted more heavily than precision. </p>\n<p><a href=\"https://en.wikipedia.org/wiki/F-score\" target=\"_blank\">https://en.wikipedia.org/wiki/F-score</a></p>",
  "messages": [
    {
      "id": "3038382",
      "postDate": "11/06/2024 22:43:27",
      "content": "<p>Just an FYI.  The general equation for the F-beta score is:</p>\n<p>$$F_{\\beta} = (1 + \\beta^2) \\cdot \\frac{precision \\cdot recall}{(\\beta^2 \\cdot precision) + recall}$$</p>\n<p>So if you're familiar with F1 Score it's just F-beta with beta = 1.</p>\n<p>$$F_{1} = 2 \\cdot \\frac{precision \\cdot recall}{precision + recall}$$</p>\n<p>For this competition, we use beta = 4:</p>\n<p>$$F_{4} = 17 \\cdot \\frac{precision \\cdot recall}{16 \\cdot precision + recall}$$</p>\n<p>Plugging in values of 0.8 for precision and 0.9 for recall gives an F4 score of 0.893.  Swapping the values gives an F4 score of 0.805 so you can see that recall is indeed weighted more heavily than precision. </p>\n<p><a href=\"https://en.wikipedia.org/wiki/F-score\" target=\"_blank\">https://en.wikipedia.org/wiki/F-score</a></p>",
      "rawMarkdown": "Just an FYI.  The general equation for the F-beta score is:\n\n$$F_{\\beta} = (1 + \\beta^2) \\cdot \\frac{precision \\cdot recall}{(\\beta^2 \\cdot precision) + recall}$$\n\nSo if you're familiar with F1 Score it's just F-beta with beta = 1.\n\n$$F_{1} = 2 \\cdot \\frac{precision \\cdot recall}{precision + recall}$$\n\nFor this competition, we use beta = 4:\n\n$$F_{4} = 17 \\cdot \\frac{precision \\cdot recall}{16 \\cdot precision + recall}$$\n\nPlugging in values of 0.8 for precision and 0.9 for recall gives an F4 score of 0.893.  Swapping the values gives an F4 score of 0.805 so you can see that recall is indeed weighted more heavily than precision. \n\n[https://en.wikipedia.org/wiki/F-score](https://en.wikipedia.org/wiki/F-score)",
      "votes": null
    },
    {
      "id": "3040182",
      "postDate": "11/08/2024 19:48:28",
      "content": "<p>The torchmetrics documentation on the F-beta score might also be of interest here:</p>\n<p><a href=\"https://lightning.ai/docs/torchmetrics/stable/classification/fbeta_score.html\" target=\"_blank\">https://lightning.ai/docs/torchmetrics/stable/classification/fbeta_score.html</a></p>",
      "rawMarkdown": "The torchmetrics documentation on the F-beta score might also be of interest here:\n\nhttps://lightning.ai/docs/torchmetrics/stable/classification/fbeta_score.html",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 3040182,
      "author_name": "frenio",
      "author_url": "",
      "post_date": "11/08/2024 19:48:28",
      "content": "<p>The torchmetrics documentation on the F-beta score might also be of interest here:</p>\n<p><a href=\"https://lightning.ai/docs/torchmetrics/stable/classification/fbeta_score.html\" target=\"_blank\">https://lightning.ai/docs/torchmetrics/stable/classification/fbeta_score.html</a></p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "3038382": "Just an FYI.  The general equation for the F-beta score is:\n\n$$F_{\\beta} = (1 + \\beta^2) \\cdot \\frac{precision \\cdot recall}{(\\beta^2 \\cdot precision) + recall}$$\n\nSo if you're familiar with F1 Score it's just F-beta with beta = 1.\n\n$$F_{1} = 2 \\cdot \\frac{precision \\cdot recall}{precision + recall}$$\n\nFor this competition, we use beta = 4:\n\n$$F_{4} = 17 \\cdot \\frac{precision \\cdot recall}{16 \\cdot precision + recall}$$\n\nPlugging in values of 0.8 for precision and 0.9 for recall gives an F4 score of 0.893.  Swapping the values gives an F4 score of 0.805 so you can see that recall is indeed weighted more heavily than precision. \n\n[https://en.wikipedia.org/wiki/F-score](https://en.wikipedia.org/wiki/F-score)",
    "3040182": "The torchmetrics documentation on the F-beta score might also be of interest here:\n\nhttps://lightning.ai/docs/torchmetrics/stable/classification/fbeta_score.html"
  },
  "source": "meta"
}