Skip to content

Shrink the size of some FreeLists.#20

Open
tavianator wants to merge 1 commit intotaku910:masterfrom
Maluuba:shrink-free-lists
Open

Shrink the size of some FreeLists.#20
tavianator wants to merge 1 commit intotaku910:masterfrom
Maluuba:shrink-free-lists

Conversation

@tavianator
Copy link
Copy Markdown

These FreeLists were responsible for 5.4MiB of allocations per query.
This is an excessive amount for systems that may have hundreds or
thousands of queries in flight at any particular time. They are now
shrunk to 82KiB per query.

The sizes were determined by some internal experimentation; they are the
smallest sizes that didn't cause reallocations on a typical NER task
(for us). YMMV for other tasks.

These FreeLists were responsible for 5.4MiB of allocations per query.
This is an excessive amount for systems that may have hundreds or
thousands of queries in flight at any particular time.  They are now
shrunk to 82KiB per query.

The sizes were determined by some internal experimentation; they are the
smallest sizes that didn't cause reallocations on a typical NER task
(for us).  YMMV for other tasks.
@tavianator
Copy link
Copy Markdown
Author

In our internal benchmarks, this increased tagging performance between 10-30X, depending on the size of the CRF.

@tavianator
Copy link
Copy Markdown
Author

Furthermore, training time stayed the same, within 0.03%.

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

Successfully merging this pull request may close these issues.

1 participant