{
  "id": 524159,
  "title": "Spine Rookie's SOS",
  "url": "/competitions/rsna-2024-lumbar-spine-degenerative-classification/discussion/524159",
  "author_name": "",
  "post_date": "2024-08-04T23:31:12.810528100Z",
  "votes": null,
  "comment_count": 3,
  "views": 0,
  "content": "<p>Eyy, vertebrae virtuosos.Khaled here.<br>\nSpine anatomy? Greek to me. Kaggle setup? A maze.<br>\nCan't submit to the leaderboard. It's killin' me. I am struggling building a pipeline that take input and make a submission into the leaderboard. That is my main goal for now.  <br>\nLookin' for a pipeline blueprint. Help a wiseguy out?<br>\nIf not, I'll muscle through solo.<br>\nNow, if you'll excuse me, I've got some vertebrae to crack haha 🤣</p>",
  "messages": [
    {
      "id": "2947053",
      "postDate": "08/04/2024 23:31:12",
      "content": "<p>Eyy, vertebrae virtuosos.Khaled here.<br>\nSpine anatomy? Greek to me. Kaggle setup? A maze.<br>\nCan't submit to the leaderboard. It's killin' me. I am struggling building a pipeline that take input and make a submission into the leaderboard. That is my main goal for now.  <br>\nLookin' for a pipeline blueprint. Help a wiseguy out?<br>\nIf not, I'll muscle through solo.<br>\nNow, if you'll excuse me, I've got some vertebrae to crack haha 🤣</p>",
      "rawMarkdown": "Eyy, vertebrae virtuosos.Khaled here.\nSpine anatomy? Greek to me. Kaggle setup? A maze.\nCan't submit to the leaderboard. It's killin' me. I am struggling building a pipeline that take input and make a submission into the leaderboard. That is my main goal for now.  \nLookin' for a pipeline blueprint. Help a wiseguy out?\nIf not, I'll muscle through solo.\nNow, if you'll excuse me, I've got some vertebrae to crack haha 🤣",
      "votes": null
    },
    {
      "id": "2947298",
      "postDate": "08/05/2024 05:50:34",
      "content": "<p>Look under <a href=\"https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code\" target=\"_blank\">Code</a> tab of this competition. Various people have given both training and inference notebooks. Example:</p>\n<ul>\n<li><a href=\"https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-training-densenet\" target=\"_blank\">RSNA2024 LSDC Training DenseNet</a></li>\n<li><a href=\"https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-densenet-submission\" target=\"_blank\">RSNA2024 LSDC DenseNet Submission</a></li>\n</ul>",
      "rawMarkdown": "Look under [Code](https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code) tab of this competition. Various people have given both training and inference notebooks. Example:\n- [RSNA2024 LSDC Training DenseNet](https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-training-densenet)\n- [RSNA2024 LSDC DenseNet Submission](https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-densenet-submission)",
      "votes": null
    },
    {
      "id": "2949697",
      "postDate": "08/06/2024 22:09:50",
      "content": "<p>Thanks for the heads up, <a href=\"https://www.kaggle.com/coderrkj\" target=\"_blank\">@coderrkj</a> <br>\n I appreciate your time<br>\nIll check them for sure</p>",
      "rawMarkdown": "Thanks for the heads up, @coderrkj \n I appreciate your time\nIll check them for sure",
      "votes": null
    },
    {
      "id": "2949886",
      "postDate": "08/07/2024 03:34:54",
      "content": "<p>There a a lot of awesome sharings in <a href=\"https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code\" target=\"_blank\">Code</a>. Here is a minimal submission script:</p>\n<pre><code> pandas  pd\n\ndf = pd.read_csv(\n    \n)\n\n\nCONDITIONS = [\n    , \n    , \n    ,\n    ,\n    \n]\nLEVELS = [\n    ,\n    ,\n    ,\n    ,\n    ,\n]\n\n random  random\n numpy  np\n\n ():\n    \n     [, , ]\n\nsubmission_df = []\n study_id  df[].unique():\n    \n     condition  CONDITIONS:\n         level  LEVELS:\n            new_row = [\n                .join([(study_id), condition, level])\n            ]\n            new_row += predict()\n            submission_df.append(new_row)\nsubmission_df = pd.DataFrame(submission_df, columns=[, , , ])\nsubmission_df.to_csv(, index=)\n</code></pre>\n<p>you may replace predict() with your model inference code and pass everything you need like study_id, etc.</p>",
      "rawMarkdown": "There a a lot of awesome sharings in [Code](https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code). Here is a minimal submission script:\n```\nimport pandas as pd\n\ndf = pd.read_csv(\n    '/kaggle/input/rsna-2024-lumbar-spine-degenerative-classification/test_series_descriptions.csv'\n)\n\n# need to predict every condiction_level (total 25) for every study\nCONDITIONS = [\n    'spinal_canal_stenosis', \n    'left_neural_foraminal_narrowing', \n    'right_neural_foraminal_narrowing',\n    'left_subarticular_stenosis',\n    'right_subarticular_stenosis'\n]\nLEVELS = [\n    'l1_l2',\n    'l2_l3',\n    'l3_l4',\n    'l4_l5',\n    'l5_s1',\n]\n\nfrom random import random\nimport numpy as np\n\ndef predict():\n    # return [\"normal_mild\", \"moderate\", \"severe\"] scores for every studyid_condition_level\n    return [0.6, 0.3, 0.1]\n\nsubmission_df = []\nfor study_id in df[\"study_id\"].unique():\n    # depends on your model's output\n    for condition in CONDITIONS:\n        for level in LEVELS:\n            new_row = [\n                \"_\".join([str(study_id), condition, level])\n            ]\n            new_row += predict()\n            submission_df.append(new_row)\nsubmission_df = pd.DataFrame(submission_df, columns=[\"row_id\", \"normal_mild\", \"moderate\", \"severe\"])\nsubmission_df.to_csv('submission.csv', index=False)\n```\nyou may replace predict() with your model inference code and pass everything you need like study_id, etc.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 2947298,
      "author_name": "coderrkj",
      "author_url": "",
      "post_date": "08/05/2024 05:50:34",
      "content": "<p>Look under <a href=\"https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code\" target=\"_blank\">Code</a> tab of this competition. Various people have given both training and inference notebooks. Example:</p>\n<ul>\n<li><a href=\"https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-training-densenet\" target=\"_blank\">RSNA2024 LSDC Training DenseNet</a></li>\n<li><a href=\"https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-densenet-submission\" target=\"_blank\">RSNA2024 LSDC DenseNet Submission</a></li>\n</ul>",
      "votes": null,
      "replies": [
        {
          "id": 2949697,
          "author_name": "tinkerturbo",
          "author_url": "",
          "post_date": "08/06/2024 22:09:50",
          "content": "<p>Thanks for the heads up, <a href=\"https://www.kaggle.com/coderrkj\" target=\"_blank\">@coderrkj</a> <br>\n I appreciate your time<br>\nIll check them for sure</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 2949886,
      "author_name": "lishaoyu",
      "author_url": "",
      "post_date": "08/07/2024 03:34:54",
      "content": "<p>There a a lot of awesome sharings in <a href=\"https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code\" target=\"_blank\">Code</a>. Here is a minimal submission script:</p>\n<pre><code> pandas  pd\n\ndf = pd.read_csv(\n    \n)\n\n\nCONDITIONS = [\n    , \n    , \n    ,\n    ,\n    \n]\nLEVELS = [\n    ,\n    ,\n    ,\n    ,\n    ,\n]\n\n random  random\n numpy  np\n\n ():\n    \n     [, , ]\n\nsubmission_df = []\n study_id  df[].unique():\n    \n     condition  CONDITIONS:\n         level  LEVELS:\n            new_row = [\n                .join([(study_id), condition, level])\n            ]\n            new_row += predict()\n            submission_df.append(new_row)\nsubmission_df = pd.DataFrame(submission_df, columns=[, , , ])\nsubmission_df.to_csv(, index=)\n</code></pre>\n<p>you may replace predict() with your model inference code and pass everything you need like study_id, etc.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "2947053": "Eyy, vertebrae virtuosos.Khaled here.\nSpine anatomy? Greek to me. Kaggle setup? A maze.\nCan't submit to the leaderboard. It's killin' me. I am struggling building a pipeline that take input and make a submission into the leaderboard. That is my main goal for now.  \nLookin' for a pipeline blueprint. Help a wiseguy out?\nIf not, I'll muscle through solo.\nNow, if you'll excuse me, I've got some vertebrae to crack haha 🤣",
    "2947298": "Look under [Code](https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code) tab of this competition. Various people have given both training and inference notebooks. Example:\n- [RSNA2024 LSDC Training DenseNet](https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-training-densenet)\n- [RSNA2024 LSDC DenseNet Submission](https://www.kaggle.com/code/hugowjd/rsna2024-lsdc-densenet-submission)",
    "2949697": "Thanks for the heads up, @coderrkj \n I appreciate your time\nIll check them for sure",
    "2949886": "There a a lot of awesome sharings in [Code](https://www.kaggle.com/competitions/rsna-2024-lumbar-spine-degenerative-classification/code). Here is a minimal submission script:\n```\nimport pandas as pd\n\ndf = pd.read_csv(\n    '/kaggle/input/rsna-2024-lumbar-spine-degenerative-classification/test_series_descriptions.csv'\n)\n\n# need to predict every condiction_level (total 25) for every study\nCONDITIONS = [\n    'spinal_canal_stenosis', \n    'left_neural_foraminal_narrowing', \n    'right_neural_foraminal_narrowing',\n    'left_subarticular_stenosis',\n    'right_subarticular_stenosis'\n]\nLEVELS = [\n    'l1_l2',\n    'l2_l3',\n    'l3_l4',\n    'l4_l5',\n    'l5_s1',\n]\n\nfrom random import random\nimport numpy as np\n\ndef predict():\n    # return [\"normal_mild\", \"moderate\", \"severe\"] scores for every studyid_condition_level\n    return [0.6, 0.3, 0.1]\n\nsubmission_df = []\nfor study_id in df[\"study_id\"].unique():\n    # depends on your model's output\n    for condition in CONDITIONS:\n        for level in LEVELS:\n            new_row = [\n                \"_\".join([str(study_id), condition, level])\n            ]\n            new_row += predict()\n            submission_df.append(new_row)\nsubmission_df = pd.DataFrame(submission_df, columns=[\"row_id\", \"normal_mild\", \"moderate\", \"severe\"])\nsubmission_df.to_csv('submission.csv', index=False)\n```\nyou may replace predict() with your model inference code and pass everything you need like study_id, etc."
  },
  "source": "meta"
}