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

源码除版本不匹配外的问题 #401

Open
Ankyiuu opened this issue Aug 30, 2024 · 1 comment
Open

源码除版本不匹配外的问题 #401

Ankyiuu opened this issue Aug 30, 2024 · 1 comment

Comments

@Ankyiuu
Copy link

Ankyiuu commented Aug 30, 2024

在初始化data_processor时,labels被初始化为set(),但在后续的代码中多次使用了self.labels.append()方法,导致在读入预先的label_list文件时会出现问题,无法读入,源代码在此处except,同时由于调试信息过多,很难发现。这样会导致最终实际标签全部是由训练数据导入的,当训练数据过多时会出现漏标的情况。
事实上用set是为了避免重复的标签类型,然而在python3.7以前,set实现是无序的,也就是说,重复训练某一模型时可能会导致label2id输出的结果不同,但我在修改其为list后也出现了这个情况,labels中并没有按我既定的输入输出数据按序输出,不知道是什么情况

@Ankyiuu
Copy link
Author

Ankyiuu commented Aug 30, 2024

同时在源码中args中虽然有-labels_list选项,但实际上最终并没有传入,就是说这里有两个bug

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

1 participant