Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

测试时出现<unk>问题 #5

Open
zhongboyin opened this issue Jun 27, 2017 · 8 comments
Open

测试时出现<unk>问题 #5

zhongboyin opened this issue Jun 27, 2017 · 8 comments

Comments

@zhongboyin
Copy link

请问程序测试结果中为什么会有这样一条:
#################### ON VALIDATION SET START ####################
TAG Prec Recall
0.0000 0.0000

@jingjing-gong
Copy link
Member

因为代码重用了vocab类,你不想看到unk可以载入tag词典的时候pop掉unk

@zhongboyin
Copy link
Author

能详细说一下怎么做么?

@zhongboyin
Copy link
Author

我更换了训练集和测试集,格式与原始数据集一样,但在测试的时候显示的精度和召回率为1 ,其他类别都是0,请赐教!

@zhongboyin
Copy link
Author

unk的召回率和精度为1

@jingjing-gong
Copy link
Member

你换数据集需要重新做词表以及类别词表也就是id2tag.txt文件

@zhongboyin
Copy link
Author

id2tag.txt 就是标签样式和样本容量吧?我已经修改了
vocab.txt 这个文件也需要修改么?
另外,这个模型的三种模式(lstm,cnn,cbow)的损失函数只有softmax么?代码中有negative samples loss function的选项么?
谢谢

@jingjing-gong
Copy link
Member

数据集换了id2tag.txt 以及vocab.txt都需要重新根据自己的数据集生成。没有negative samples loss function你可以看代码自己加上就好了。

@zhongboyin
Copy link
Author

vocab.txt是词频分布情况吧?请问已有的vocab.txt文件是怎么生成的?如果是代码,求分享!
谢谢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants