打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
成功解决TypeError: __init__() got an unexpected keyword argument ''n_iterations''



解决问题

TypeError: __init__() got an unexpected keyword argument 'n_iterations'

解决思路

类型错误:得到意外的关键字参数“n_iterations”

解决方法

先尝试把多余的参数去掉,如果不行就升级函数包即可!

cv=StratifiedShuffleSplit(Y_train, n_iter=10, test_size=0.2, train_size=None, indices=None,                                                      random_state=seed, n_iterations=None)).fit(X_train, Y_train)

改为

cv=StratifiedShuffleSplit(Y_train, n_iter=10, test_size=0.2, train_size=None, indices=None,                                                      random_state=seed)).fit(X_train, Y_train)

大功告成!哈哈!

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
horus questions
TypeError: __init__() missing 1 required positional argument: 'on_delete'
函数所有的知识点都在此篇文章里,函数就相当于建房子的基石!
Mnist数据集分类简单版本 Iter: 399 , Testing Accuracy 0.9131
2018北京石景山初三一模英语(教师版)
Unexpected Exception: TypeError: result is null.
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服