当前位置:网站首页>训练集调优时的数据分割小览
训练集调优时的数据分割小览
2022-04-21 08:04:00 【weixin_38871988】
knn结束另附:数据分割及训练集调优时的数据分割
测试集应该尽可能与训练集互斥
留出法
自助法
交叉验证法
留一法是留出法中的一种
交叉验证法
KFold和StratifiedKFold
都在,sklearn.model_seletion里
交叉验证实现方法,除了咱们前面讲的GridSearchCV之外,还有KFold, StratifiedKFold
用法:
将训练/测试数据集划分n_splits个互斥子集,每次用其中一个子集当作验证集,剩下的n_splits-1个作为训练集,进行n_splits次训练和测试,得到n_splits个结果
StratifiedKFold的用法和KFold的区别是:SKFold是分层采样,确保训练集,测试集中,各类别样本的比例是和原始数据集中的一致。
KFold不对训练集里的正反例均匀采样

StratifiedKFold考虑到正反例,分类的占比情况
自助法

有放回抽样,取极限时,有0.368的概率取不到
因此把这部分数据拿出来做测试集
数据量小,交叉验证法
数据量特别小,留一法
自助法,取其中
这样的测试结果,亦称“包外估计”(out- of-bagestimate)
版权声明
本文为[weixin_38871988]所创,转载请带上原文链接,感谢
https://blog.csdn.net/weixin_38871988/article/details/109543990
边栏推荐
- 不确定是 BUG 还是设定
- Differences among directory, folder and file
- Class loading and class loader overview
- 解决数据库无法启动
- kernel-pwn学习(1)--环境搭建
- SQL Server 数据库之SQL Server 数据库的安全设置
- pydeck助数百万数据点高效可视化渲染
- autojs连接不上电脑,提示连接失败,权限不足
- Arm64 architecture programming and practice: arithmetic and shift instructions
- Record the fuck string of C # to Base64 and Base64 restore string
猜你喜欢

【读书笔记->统计学】07-01 离散型概率分布-几何分布概念简介
![Introduction to ACM [tree diameter]](/img/d7/90508341730e42881271f16c9c0672.png)
Introduction to ACM [tree diameter]
![[get C] how data is stored in memory](/img/08/9ee2bfa3025ebe3133cf8c149b80fd.png)
[get C] how data is stored in memory

webapi(六)- BOM

If ehcache is changed to redis cache according to the requirements, the detailed integration steps are as follows:

牛客白月赛4 【题解】

Be sure to look at the nine steps of MES model selection. Which step did you miss? (top)

关于安卓开发真机调试中创建SQLite数据库不成功的问题
![[introduction to C language series (8) (9)] Chapter 8 and 9, pointer and structure](/img/98/33ce4ce21f036ace1b75cdddb4f158.png)
[introduction to C language series (8) (9)] Chapter 8 and 9, pointer and structure

SQL Server 数据库之SQL Server 数据库的安全设置
随机推荐
神经网络学习之Opencv使用记录
pip安装成功,但是pycharm报错的问题
关于写DMF时发生的小事情
MySQL查看字符集和校对规则
MES与ERP需要整合才能体现关键作用
Developing grpc application based on well-known micro service framework go micro
【读书笔记->统计学】07-01 离散型概率分布-几何分布概念简介
【精品】利用动态代理实现事务统一管理一
【读书笔记->统计学】07-02 离散型概率分布-二项分布概念简介
Record the fuck string of C # to Base64 and Base64 restore string
SQL Server 数据库之SQL Server 数据库的安全设置
eval()函数
web应用中的乱码问题
pydeck助数百万数据点高效可视化渲染
【读书笔记->统计学】07-03 离散型概率分布-泊松分布概念简介
6. 堪比JMeter的.Net压测工具 - Crank 实战篇 - 收集诊断跟踪信息与如何分析瓶颈
实现SPA实现单包授权技术的方案Fwknop
第五章 函数
Eval() function
Class loading and class loader overview