去除 FutureWarning报错信息

models = {}
models['LR'] = LogisticRegression()
models['LDA'] = LinearDiscriminantAnalysis()
models['KNN'] = KNeighborsClassifier()
models['CART'] = DecisionTreeClassifier()
models['NB'] = GaussianNB()
models['SVM'] = SVC()
小括号里什么都没有时,LogisticRegression和SVM就一堆的FutureWarning报错信息. 添加内容后,就没有了报错信息. models
= {} models['LR'] = LogisticRegression(solver='liblinear', multi_class='auto') models['LDA'] = LinearDiscriminantAnalysis() models['KNN'] = KNeighborsClassifier() models['CART'] = DecisionTreeClassifier() models['NB'] = GaussianNB() models['SVM'] = SVC(gamma='auto')

 

转载于:https://www.cnblogs.com/2019-02-11/p/10639169.html

你可能感兴趣的:(开发工具,数据结构与算法)