qq_43062322
2022-09-23 20:46
采纳率: 83.3%
浏览 8

'GaussianMixture' object has no attribute 'covariances_'

'GaussianMixture' object has no attribute 'covariances_'

gmm = GaussianMixture(5)
gmm.means_ = np.array([[10], [20], [60], [80], [110]])
gmm.covars_ = np.array([[3], [3], [2], [2], [1]]) ** 2
gmm.weights_ = np.array([0.2, 0.2, 0.2, 0.2, 0.2])

X = gmm.sample(200000)
然后就报错 'GaussianMixture' object has no attribute 'covariances_',请问这个怎么解决

1条回答 默认 最新

相关推荐 更多相似问题