sparkydogX / sparkydogx_blog_comment

Comments for https://sparkydogx.github.io
1 stars 0 forks source link

sklearn之分类器的使用 | SparkydogX Blog #42

Open sparkydogX opened 5 years ago

sparkydogX commented 5 years ago

https://sparkydogx.github.io/2017/09/11/sklearn/

sklearn是一个机器学习的开源库,简单好用。在sklearn中,所有的分类器都可以秉持“三步走”方法: 设置分类器 fit训练数据 使用测试集对训练好对模型进行评估 sklearn.neighbors.KNeighborsClassifier1234from sklearn.neighbors import KNeighborsClassifierneigh=KNeighborsClass