liuhuanyong / TextGrapher

Text Content Grapher based on keyinfo extraction by NLP method。输入一篇文档,将文档进行关键信息提取,进行结构化,并最终组织成图谱组织形式,形成对文章语义信息的图谱化展示。
1.37k stars 360 forks source link

运行时的问题 #4

Open Windancer94 opened 5 years ago

Windancer94 commented 5 years ago

运行出来的图谱中是乱码,是什么原因呢?

inkeast commented 5 years ago

在graph_show.py里网页模板前加一行


        <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />

就好了

Wangnanfei commented 5 years ago

网页保存的时候,增加 encoding = 'utf-8'

onewaymyway commented 5 years ago

GraphicShow.py create_html函数改一下编码就可以了 f = open('graph_show.html', 'w+',encoding='utf-8')