496. U.S. Patent Phrase to Phrase Matching | us-patent-phrase-to-phrase-matching
感谢 USPTO 和 Kaggle 主办了这场激动人心的比赛,也感谢各位 Kagglers 的精彩对决。
(2022/10/24 更新) 已添加训练和推理代码。
我创建了20个多样化的模型,并使用 Optuna 进行权重调整来完成集成。
每个单独的实验并没有显著提高 CV(交叉验证)分数,但集成显示了效果。据推测,模型的多样性对我起了作用。
| CV | 公开榜 | 私有榜 |
|---|---|---|
| 0.8535 | 0.8514 | 0.8655 |
def label_to_score(label):
return (label*[0,0.25,0.5,0.75,1.0]).sum(axis=1)
def metric_pearson(predictions, labels):
pred_score = label_to_score(predictions) # "predictions" 是模型输出
label_score = label_to_score(labels) # "labels" 是真实标签
pearson = np.corrcoef(pred_score, label_score)[0][1]
return pearson
[subgrp=A][context=A47]HUMAN NECESSITIES. FURN...
| 实验编号 | CV分数 | 任务 | 主干网络 | 头部 | 预处理 | 权重 |
|---|---|---|---|---|---|---|
| exp122 | 0.8133 | Cls | anferico/bert-for-patents | Attention | 0.8588 | |
| exp094 | 0.8143 | Reg | anferico/bert-for-patents | CLS-Token | 0.3617 | |
| exp127 | 0.8174 | Cls |