# 100th Place Silver Medal Solution

Hi Everyone, I just wanted to share my solution as well as some tricks I used to boost my score.
Overview
Kaplan–Meier Catboost with event-masking + PRL NN with event-masking
CV: 0.690
Public LB Score: 0.689
Private LB Score: 0.693
Tricks
Cross Validation Methodology
StratifiedKFold using both race group and binned target values. This ensures balanced representation of race groups and target distributions across folds.
10 folds across 30 different seeds were used for cross validation to train a total of 300 models for each unique model variant. The idea was to make the model ensemble more diverse and robust.
train[] = pd.cut(train[], =NUM_BINS, =)
train[] = train[].astype(str) +  + train[].astype(str)

 seed  SEEDS:
    skf = StratifiedKFold(=FOLDS, =, =seed)
This method significantly boosted my CV score—the more seeds I added, the higher the score. However, I stopped at 30 seeds, as my testing showed that adding more than 30 no longer improved the CV score.
Running such a meticulous CV also served another purpose: preventing me from overfitting to specific folds during testing. This methodology was both stable and reliable, giving me confidence in the feedback from my CV.
Event-Masking Using Classifiers
Classifier ensemble consisting of catboost, xgboost, and lightgbm is used for event-masking.
[pred_ensemble == ] += .
[pred_ensemble == ] += .
When applying classifier event-masking to a Catboost regressor trained on a Kaplan–Meier target, there was a huge CV improvement of about 0.01 (0.6781455227816864 --> 0.6864895241696849). Applying event-masking usually does result in improvement for many of my models, but on this Kaplan–Meier catboost the improvement is very significant.
This brought the CV of this catboost model on par to that of the PRL NN and the resulting ensemble of Kaplan–Meier catboost with event-masking + PRL NN with event-masking yielded a silver medal solution.
Closing Remarks
I learnt a lot from this competition and would like to specially give credit to
[@Albanito](https://www.kaggle.com/Albanito)
for his notebook on event-masking. (
[https://www.kaggle.com/code/albansteff/event-masked-prl-nn](https://www.kaggle.com/code/albansteff/event-masked-prl-nn)
)
Thank you.
Code and Model Files
Inference Notebook:
[https://www.kaggle.com/code/sshiyu/silver-solution-100th](https://www.kaggle.com/code/sshiyu/silver-solution-100th)
Model Files:
[https://www.kaggle.com/datasets/sshiyu/cibmtr-final-models](https://www.kaggle.com/datasets/sshiyu/cibmtr-final-models)
Model Training Code:
[https://www.kaggle.com/datasets/sshiyu/cibmtr-final-model-training-code](https://www.kaggle.com/datasets/sshiyu/cibmtr-final-model-training-code)