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

分词运行时异常 KeyError #51

Open
yuliji-seedlink opened this issue Nov 6, 2017 · 0 comments
Open

分词运行时异常 KeyError #51

yuliji-seedlink opened this issue Nov 6, 2017 · 0 comments

Comments

@yuliji-seedlink
Copy link

yuliji-seedlink commented Nov 6, 2017

运行分词是抛出异常CBTaggingDecoder的get_seg_result函数,不知道是什么原因。具体异常信息如下:thulac (0.1.1)

File "xxx/thulac/init.py", line 97, in cut
return self.__cutWithOutMethod(oiraw, self.__cutline, text = text)
File "xxx/thulac/init.py", line 90, in __cutWithOutMethod
array += (reduce(lambda x, y: x + [[y, '']], cut_method(line), []))
File "xxx/thulac/init.py", line 120, in __cutline
segged = self.__cws_tagging_decoder.get_seg_result()
File "xxx/thulac/character/CBTaggingDecoder.py", line 191, in get_seg_result
if((i == 0) or (self.labelInfo[self.result[i]][0] == '0') or (self.labelInfo[self.result[i]][0] == '3')):
KeyError: 24

@yuliji-seedlink yuliji-seedlink changed the title 分词运行时异常 分词运行时异常 KeyError Nov 6, 2017
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