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

Saving frequencies as Dictionaries may be faster than Bags #17

Open
olekscode opened this issue Mar 7, 2020 · 1 comment
Open

Saving frequencies as Dictionaries may be faster than Bags #17

olekscode opened this issue Mar 7, 2020 · 1 comment

Comments

@olekscode
Copy link
Member

Profile NgramModel with frequencies saved as Dictionary and compare it to the current one that saves frequencies in Bag

@jecisc
Copy link
Contributor

jecisc commented Feb 16, 2023

I did not check a lot the implementation but maybe we could also have a tree and each leave would be a letter. Thus, when checking the counts of "test" we would go in node "t" then "e" then "s" then "t" and it would be faster than scanning a dictonary with hundreds of thousands entries?

Once again, I don’t know this algo and just had a quick look, so maybe my solution does not fit the requirements.

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

No branches or pull requests

2 participants