Skip to content

Use dill and Apache Arrow directly for caching & storing hidden states #203

@norabelrose

Description

@norabelrose

Right now we save hidden states as a HF dataset so that we can use its magical caching abilities. We're clearly wrangling HF into supporting something it wasn't designed for and this does cause us to need to load the model from disk a bunch of times during a sweep, whereas we could load it only once if we had more control. I expect we could get at least a 2x speedup from this for large models, and the code could be cleaner. It would also remove the confusing "Downloading and preparing" messages that currently pop up when we extract hiddens

Metadata

Metadata

Assignees

No one assigned

    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