def showData(self):
print('???,????···')
mask = imread(self.picfile)
imgcolor = ImageColorGenerator(mask)
wcc = WordCloud(font_path='./msyhl.ttc',
mask=mask, background_color='white',
max_font_size=200,
max_words=300,
color_func=imgcolor
)
wc = wcc.generate_from_frequencies(self.data)
plt.figure()
plt.imshow(wc)
plt.axis('off')
print('?????')
plt.show()
评论列表
文章目录