Skip to content

How to get document's sparse vector ? #107

Answered by xhluca
Zrealshadow asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, you can save the indexes as numpy arrays.

The numpy arrays can be reloaded directly and accessed via bm25s, or even without bm25s (directly in numpy if you want).

See this end to end example: https://github.com/xhluca/bm25s/blob/main/examples/save_and_reload_end_to_end.py

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by xhluca
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #106 on January 21, 2025 17:16.