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

大噶好啊! #1

Open
ichn-hu opened this issue Jul 7, 2018 · 5 comments
Open

大噶好啊! #1

ichn-hu opened this issue Jul 7, 2018 · 5 comments

Comments

@ichn-hu
Copy link
Collaborator

ichn-hu commented Jul 7, 2018

在github上造个fudan组织是挺不错的,感谢发起者。为了方便大家互相了解,我们不如就用issue系统当作论坛好了,所以就建立了这么一个repo。

我先自我介绍一下,我是16级计算机本科生,我叫胡志峰,请大家多多指教!

@FengZiYjun
Copy link

找到这么一个组织,好像是(前)学生网的人 :D
https://github.com/STU-Fudan
要不要拉拢一下 :D

@ichn-hu
Copy link
Collaborator Author

ichn-hu commented Jul 7, 2018

阔以啊hhh

@xiaozhewen
Copy link

xiaozhewen commented Jul 19, 2018

@FengZiYjun 你好,请问这个中文分词算法对应的论文实验结果你还原出来了么,=。= 我测得PKU和MSR的和标准分割对比得出的F1值分别是79和75,跟作者的差好多

@FengZiYjun
Copy link

@xiaozhewen 你好,是可以重现的,否则我也不会用来做其他实验。我没有记录当时的结果,但不会差很远。

@xiaozhewen
Copy link

xiaozhewen commented Jul 20, 2018

@FengZiYjun 你好,谢谢回复。目前我发现的问题是这样的:
论文源码(未修改)

cws.trainer.update_epoch(1.)
end_time = time.time()
print 'Trained %s epoch(s) (%d samples) took %.lfs per epoch'%(eidx+1,nsamples,(end_time-start_time)/(eidx+1))
test(cws,dev_file,'../result/dev_result%d'%(eidx+1))
os.system('python score.py %s %d %d'%(dev_file,eidx+1,eidx+1))
cws.save('epoch%d'%(eidx+1))
print 'Current model saved'
按照README.md 运行代码,测试PKU,F1值95.1

[@gpu01 src]$ ./score ../data/pku_train ../data/pku_test ../result/dev/dev_result28 > ../../result/score/greedy_pku_test_seg.utf8
[
@gpu01 src]$ tail -n 14 ../../result/score/greedy_pku_test_seg.utf8
=== SUMMARY:
=== TOTAL INSERTIONS: 1766
=== TOTAL DELETIONS: 1496
=== TOTAL SUBSTITUTIONS: 3477
=== TOTAL NCHANGE: 6739
=== TOTAL TRUE WORD COUNT: 104371
=== TOTAL TEST WORD COUNT: 104641
=== TOTAL TRUE WORDS RECALL: 0.952
=== TOTAL TEST WORDS PRECISION: 0.950
=== F MEASURE: 0.951
=== OOV Rate: 0.927
=== OOV Recall Rate: 0.950
=== IV Recall Rate: 0.988
../result/dev/dev_result28 1766 1496 3477 6739 104371 104641 0.952 0.950 0.951 0.927 0.950 0.988

1、但是,test(cws,dev_file,'../result/dev_result%d'%(eidx+1)),测试文件dev_file是../data/pku_test文件,这个pku_test是已经分词的,test函数输出分词结果保存为../result/dev_result%d'%(eidx+1),然后运行score评分脚本,=== F MEASURE: 0.951 是分词结果pku_test对比得出。

2、分词结果标准分割icwb2-data/gold/pku_test_gold.utf8 对比=== F MEASURE: 0.843

3、运行test模式,load最好的模型,测试文件为未分词的icwb2-data/testing/pku_test.utf8,得出的分词结果和标准分割icwb2-data/gold/pku_test_gold.utf8对比是F值是79。

这是我疑惑的地方,是不是1中得出的评分结果有失偏颇,因为一是使用已分词的文本pku_test做测试,二是使用这个已分词文本作为标准分割。

很想和你详聊,不介意的话加下我QQ可好:928371104

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

3 participants