Commit a731aeac by BellCodeEditor

save project

parent 9de00fbb
Showing with 1 additions and 6 deletions
import wordcloud
from PIL import Image
import numpy
img=wordcloud.open("bell.png")
data=img.array(img)
img_colors=wordcloud.ImageColorGenerator(data)
w=wordcloud.WordCloud(background_color="write",font_path='SimHei.ttf',mask=data,color_fanc=img_colors)
w=wordcloud.WordCloud(background_color="write",font_path='SimHei.ttf')
with open("python二级考试大纲.txt","r",encoding='utf-8')as f:
a=f.read()
w.generate(a)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment