#词云.py
import wordcloud #导入词云库
w=wordcloud.WordCloud(width=600,height=600)#配置对象参数并赋值
txt='hello python hello python\
hello python hello python \
hello python'
w.generate(txt) #加载文本内容
w.to_file('词云.png')
#词云.py
import wordcloud #导入词云库
w=wordcloud.WordCloud(width=600,height=600)#配置对象参数并赋值
txt='hello python hello python\
hello python hello python \
hello python'
w.generate(txt) #加载文本内容
w.to_file('词云.png')