赞
踩
成功解决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)
大功告成!哈哈!
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。