Commit a088710a by BellCodeEditor

save project

parent fab832c5
...@@ -2,7 +2,7 @@ import wordcloud ...@@ -2,7 +2,7 @@ import wordcloud
from PIL import Image from PIL import Image
import numpy import numpy
import jieba import jieba
zhu2=Image.open(".png") zhu2=Image.open("bell.png")
zhu3=numpy.array(zhu2) zhu3=numpy.array(zhu2)
zhu4 = wordcloud.ImageColorGenerator(zhu3) zhu4 = wordcloud.ImageColorGenerator(zhu3)
zhu5=["的","python","和","基本","程序"] zhu5=["的","python","和","基本","程序"]
...@@ -12,4 +12,4 @@ with open('python二级考试大纲.txt','r',encoding='utf-8') as f: ...@@ -12,4 +12,4 @@ with open('python二级考试大纲.txt','r',encoding='utf-8') as f:
zhu1=jieba.lcut(zhu1) zhu1=jieba.lcut(zhu1)
zhu1=" ".join(zhu1) zhu1=" ".join(zhu1)
zhu.generate(zhu1) zhu.generate(zhu1)
zhu.to_file("zhuzhuzhuzhuzhuzhu.png") zhu.to_file("z.png")
\ No newline at end of file \ No newline at end of file
z.png

220 KB

65.3 KB | W: | H:

65.5 KB | W: | H:

zhuzhuzhuzhuzhuzhu.png
zhuzhuzhuzhuzhuzhu.png
zhuzhuzhuzhuzhuzhu.png
zhuzhuzhuzhuzhuzhu.png
  • 2-up
  • Swipe
  • Onion skin
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