scikit-learn Plot classification probability
# 资料汇入
iris = datasets.load_iris()
X = iris.data[:, 0:2] # we only take the first two features for visualization
y = iris.target # 目标资料
# print(X.shape) 得到x的shape ,shape[0] 返回的是第一维度长度,shape[1] 返回第二维度长度
n_features = X.shape[1] # 0,图像的高度 1,图像的宽度 2,图像的通
原创
2021-11-09 20:21:10 ·
1315 阅读 ·
0 评论