{
  "id": 566686,
  "title": "6th Place Solution",
  "content": "<p>Hey everyone,<br>\n<img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F1630287%2Fd60afc32dfc0a18e8be5181338bc77a8%2Fsol.png?generation=1741271198455281&amp;alt=media\" alt=\"\"></p>\n<p>I've made public the notebook that earned me 6th place:<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-two-step-model\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-two-step-model</a></p>\n<p>Here is the summary of what it does</p>\n<h3>1. Gradient Boosting Models</h3>\n<ul>\n<li>Use gradient boosting models to predict:<ul>\n<li><strong>p(efs == 1)</strong>: the probability that the event occurs.</li>\n<li><strong>E[efs_time | efs == 1]</strong>: the expected survival time conditioned on the event occurring.</li></ul></li>\n</ul>\n<h3>2. Neural Network</h3>\n<ul>\n<li>Train a TabM neural network that optimizes a smoothed version of the evaluation metric (using a sigmoid instead of the indicator function).</li>\n</ul>\n<h3>3. Combine the Predictions</h3>\n<ul>\n<li>Run 20-fold cross-validation with 5 random seeds for all models.</li>\n<li>Train a one-layer neural network (with no non-linearities) on out-of-fold (OOF) data, with the same loss function as the TabM model.  </li>\n<li><strong>Inputs to the NN:</strong><ul>\n<li><strong>Risk score from the TabM model</strong></li>\n<li><strong>2nd-order polynomial combinations</strong> of <strong>p(efs == 1)</strong> and <strong>E[efs_time | efs == 1]</strong></li></ul></li>\n</ul>\n<p>I can publish code for individual parts of the solution as well if anyone is interested.</p>",
  "comments": [
    {
      "id": 3143281,
      "author_name": "Oleg Khudyakov",
      "author_url": "",
      "post_date": "2025-03-07T04:31:48.787000",
      "content": "<p>Hello, Alexandr!<br>\nCongratulations with gold medal!<br>\nI would be very grate full if You share full solution for all parts.</p>",
      "votes": 1,
      "replies": [
        {
          "id": 3143458,
          "author_name": "Aleksandr Timofeev",
          "author_url": "",
          "post_date": "2025-03-07T08:55:17.783000",
          "content": "<p>Hi, thanks!</p>\n<p>Here you go</p>\n<p>Hyperparameter search for Catboost. For XGBoost and LightGBM, only the parameter names/ranges are different.<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-catboost-classifier-parameter-search\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-catboost-classifier-parameter-search</a><br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-catboost-regressor-parameter-search\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-catboost-regressor-parameter-search</a></p>\n<p>Finding weights for gradient boosting models<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-gradient-boosting-weights\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-gradient-boosting-weights</a></p>\n<p>Preparing OOF dataset for the linear model<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-oof-dataset\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-oof-dataset</a></p>\n<p>Training the linear model<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-second-step-model-training\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-second-step-model-training</a></p>",
          "votes": 5,
          "replies": []
        }
      ]
    },
    {
      "id": 3142834,
      "author_name": "Robert Hatch",
      "author_url": "",
      "post_date": "2025-03-06T17:41:12.533000",
      "content": "<p>Congrats on gold!</p>\n<p>For those keeping track at home, at least top 7 all did this model efs and model efs==1 efs_time rank separately trick. </p>\n<p>I suspect it was only so critical due to synthetic data. But maybe the nature of the metric alone makes it critical. Reduce 2 dimensional label down to one dimension prediction… but then calculate score against the original two dimensions(!)</p>",
      "votes": 1,
      "replies": [
        {
          "id": 3142971,
          "author_name": "Aleksandr Timofeev",
          "author_url": "",
          "post_date": "2025-03-06T19:45:33.913000",
          "content": "<p>Thanks!<br>\nNo clue why this is so crucial 🙂</p>",
          "votes": 0,
          "replies": [
            {
              "id": 3142987,
              "author_name": "Robert Hatch",
              "author_url": "",
              "post_date": "2025-03-06T20:02:28.407000",
              "content": "<p>I suspect the synthetic data generation approach is the only reason. But not confident about it, just hypothesis. </p>",
              "votes": 0,
              "replies": []
            }
          ]
        }
      ]
    },
    {
      "id": 3143740,
      "author_name": "Nicolae Cadin",
      "author_url": "",
      "post_date": "2025-03-07T14:41:16.670000",
      "content": "<p>Congratulations on the gold! Thank you for sharing your well-written notebook.</p>",
      "votes": 0,
      "replies": []
    }
  ],
  "comment_count": 6,
  "messages": [
    {
      "id": 3142613,
      "postDate": "2025-03-06T14:34:33.633Z",
      "content": "<p>Hey everyone,<br>\n<img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F1630287%2Fd60afc32dfc0a18e8be5181338bc77a8%2Fsol.png?generation=1741271198455281&amp;alt=media\" alt=\"\"></p>\n<p>I've made public the notebook that earned me 6th place:<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-two-step-model\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-two-step-model</a></p>\n<p>Here is the summary of what it does</p>\n<h3>1. Gradient Boosting Models</h3>\n<ul>\n<li>Use gradient boosting models to predict:<ul>\n<li><strong>p(efs == 1)</strong>: the probability that the event occurs.</li>\n<li><strong>E[efs_time | efs == 1]</strong>: the expected survival time conditioned on the event occurring.</li></ul></li>\n</ul>\n<h3>2. Neural Network</h3>\n<ul>\n<li>Train a TabM neural network that optimizes a smoothed version of the evaluation metric (using a sigmoid instead of the indicator function).</li>\n</ul>\n<h3>3. Combine the Predictions</h3>\n<ul>\n<li>Run 20-fold cross-validation with 5 random seeds for all models.</li>\n<li>Train a one-layer neural network (with no non-linearities) on out-of-fold (OOF) data, with the same loss function as the TabM model.  </li>\n<li><strong>Inputs to the NN:</strong><ul>\n<li><strong>Risk score from the TabM model</strong></li>\n<li><strong>2nd-order polynomial combinations</strong> of <strong>p(efs == 1)</strong> and <strong>E[efs_time | efs == 1]</strong></li></ul></li>\n</ul>\n<p>I can publish code for individual parts of the solution as well if anyone is interested.</p>",
      "rawMarkdown": "Hey everyone,\n![](https://www.googleapis.com/download/storage/v1/b/kaggle-forum-message-attachments/o/inbox%2F1630287%2Fd60afc32dfc0a18e8be5181338bc77a8%2Fsol.png?generation=1741271198455281&alt=media)\n\nI've made public the notebook that earned me 6th place:\nhttps://www.kaggle.com/code/myprofileurl/6th-place-two-step-model\n\nHere is the summary of what it does\n\n### 1. Gradient Boosting Models  \n- Use gradient boosting models to predict:\n  - **p(efs == 1)**: the probability that the event occurs.\n  - **E[efs_time | efs == 1]**: the expected survival time conditioned on the event occurring.\n\n### 2. Neural Network  \n- Train a TabM neural network that optimizes a smoothed version of the evaluation metric (using a sigmoid instead of the indicator function).\n\n### 3. Combine the Predictions  \n- Run 20-fold cross-validation with 5 random seeds for all models.\n- Train a one-layer neural network (with no non-linearities) on out-of-fold (OOF) data, with the same loss function as the TabM model.  \n- **Inputs to the NN:**\n  - **Risk score from the TabM model**\n  - **2nd-order polynomial combinations** of **p(efs == 1)** and **E[efs_time | efs == 1]**\n\nI can publish code for individual parts of the solution as well if anyone is interested.\n",
      "votes": 25
    },
    {
      "id": 3143281,
      "postDate": "2025-03-07T04:31:48.787Z",
      "content": "<p>Hello, Alexandr!<br>\nCongratulations with gold medal!<br>\nI would be very grate full if You share full solution for all parts.</p>",
      "rawMarkdown": "Hello, Alexandr!\nCongratulations with gold medal!\nI would be very grate full if You share full solution for all parts.",
      "votes": 1,
      "replies": [
        {
          "id": 3143458,
          "postDate": "2025-03-07T08:55:17.783Z",
          "content": "<p>Hi, thanks!</p>\n<p>Here you go</p>\n<p>Hyperparameter search for Catboost. For XGBoost and LightGBM, only the parameter names/ranges are different.<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-catboost-classifier-parameter-search\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-catboost-classifier-parameter-search</a><br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-catboost-regressor-parameter-search\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-catboost-regressor-parameter-search</a></p>\n<p>Finding weights for gradient boosting models<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-gradient-boosting-weights\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-gradient-boosting-weights</a></p>\n<p>Preparing OOF dataset for the linear model<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-oof-dataset\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-oof-dataset</a></p>\n<p>Training the linear model<br>\n<a href=\"https://www.kaggle.com/code/myprofileurl/6th-place-second-step-model-training\" target=\"_blank\">https://www.kaggle.com/code/myprofileurl/6th-place-second-step-model-training</a></p>",
          "rawMarkdown": "Hi, thanks!\n\nHere you go\n\nHyperparameter search for Catboost. For XGBoost and LightGBM, only the parameter names/ranges are different.\nhttps://www.kaggle.com/code/myprofileurl/6th-place-catboost-classifier-parameter-search\nhttps://www.kaggle.com/code/myprofileurl/6th-place-catboost-regressor-parameter-search\n\nFinding weights for gradient boosting models\nhttps://www.kaggle.com/code/myprofileurl/6th-place-gradient-boosting-weights\n\nPreparing OOF dataset for the linear model\nhttps://www.kaggle.com/code/myprofileurl/6th-place-oof-dataset\n\nTraining the linear model\nhttps://www.kaggle.com/code/myprofileurl/6th-place-second-step-model-training",
          "votes": 5
        }
      ]
    },
    {
      "id": 3142834,
      "postDate": "2025-03-06T17:41:12.533Z",
      "content": "<p>Congrats on gold!</p>\n<p>For those keeping track at home, at least top 7 all did this model efs and model efs==1 efs_time rank separately trick. </p>\n<p>I suspect it was only so critical due to synthetic data. But maybe the nature of the metric alone makes it critical. Reduce 2 dimensional label down to one dimension prediction… but then calculate score against the original two dimensions(!)</p>",
      "rawMarkdown": "Congrats on gold!\n\nFor those keeping track at home, at least top 7 all did this model efs and model efs==1 efs_time rank separately trick. \n\nI suspect it was only so critical due to synthetic data. But maybe the nature of the metric alone makes it critical. Reduce 2 dimensional label down to one dimension prediction... but then calculate score against the original two dimensions(!)",
      "votes": 1,
      "replies": [
        {
          "id": 3142971,
          "postDate": "2025-03-06T19:45:33.913Z",
          "content": "<p>Thanks!<br>\nNo clue why this is so crucial 🙂</p>",
          "rawMarkdown": "Thanks!\nNo clue why this is so crucial 🙂",
          "replies": [
            {
              "id": 3142987,
              "postDate": "2025-03-06T20:02:28.407Z",
              "content": "<p>I suspect the synthetic data generation approach is the only reason. But not confident about it, just hypothesis. </p>",
              "rawMarkdown": "I suspect the synthetic data generation approach is the only reason. But not confident about it, just hypothesis. "
            }
          ]
        }
      ]
    },
    {
      "id": 3143740,
      "postDate": "2025-03-07T14:41:16.670Z",
      "content": "<p>Congratulations on the gold! Thank you for sharing your well-written notebook.</p>",
      "rawMarkdown": "Congratulations on the gold! Thank you for sharing your well-written notebook."
    }
  ],
  "complete": true,
  "source": "live",
  "fetched_at": "2026-10-19T19:48:40Z",
  "competition_id": 70942,
  "competition_slug": "equity-post-HCT-survival-predictions",
  "team_id": 13230408,
  "solution_url": "/competitions/equity-post-HCT-survival-predictions/writeups/aleksandr-timofeev-6th-place-solution"
}