mirror of
https://github.com/fxsjy/jieba.git
synced 2025-07-10 00:01:33 +08:00
修复带权重测试脚本输出结果是调用顺序错误
This commit is contained in:
parent
cf2aa88122
commit
6772f0282e
@ -38,6 +38,6 @@ tags = jieba.analyse.extract_tags(content, topK=topK, withWeight=withWeight)
|
|||||||
|
|
||||||
if withWeight is True:
|
if withWeight is True:
|
||||||
for tag in tags:
|
for tag in tags:
|
||||||
print "tag: %s\t\t weight: %f" % (tag[1],tag[0])
|
print "tag: %s\t\t weight: %f" % (tag[0],tag[1])
|
||||||
else:
|
else:
|
||||||
print ",".join(tags)
|
print ",".join(tags)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user