Skip to content

KOMORAN에 비해서 속도가 현저히 느린 현상 발생 #4

@shin285

Description

@shin285

현재 KOMORAN과 가장 큰 차이점은 child node의 자료형이 다르다는 점임

  • KOMORANPy : AhoCorasick의 child node를 dictionary 형태로 저장 후 get 하여 가져옴
  • KOMORAN : AhoCorasick의 child node를 list 형태로 저장 후 바이너리 search 하여 가져옴

KOMORAN에서도 속도 개선을 위하여 KOMORANPy와 같이 map 형태로 child node를 저장한 적이 있었으나 오히려 속도 저하로 이어졌음.

dictionary에서 get 할 때 hashing에 드는 연산이 list에서 binary search하는 시간보다 오래 걸리기 때문인 것으로 예상 됨

AC

  • KOMORANPy에서 AhoCorasick의 child node를 list 형태로 변경 후 속도를 확인할 수 있다.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions