sklearn.cluster.KMeans中n_init参数是什么意思

-柚子皮-
人工智能领域优质创作者
博客专家认证
2014-12-20 09:34:38
n_init解释为:
Number of time the k-means algorithm will be run with different centroid seeds. The
final results will be the best output of n_init consecutive runs in terms of inertia.
设置选择质心种子次数,默认为10次。返回质心最好的一次结果(好是指计算时长短)

这个到底是嘛意思?
...全文
1829 1 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
panghuhu250 2014-12-20
  • 打赏
  • 举报
回复 1
每一次算法运行时开始的centroid seeds是随机生成的, 这样得到的结果也可能有好有坏. 所以要运行算法n_init次, 取其中最好的.

37,743

社区成员

发帖
与我相关
我的任务
社区描述
JavaScript,VBScript,AngleScript,ActionScript,Shell,Perl,Ruby,Lua,Tcl,Scala,MaxScript 等脚本语言交流。
社区管理员
  • 脚本语言(Perl/Python)社区
  • WuKongSecurity@BOB
加入社区
  • 近7日
  • 近30日
  • 至今

试试用AI创作助手写篇文章吧