v.19.15New Feature
Add a Sparse_hashed Dictionary Layout, That Is Functionally Equivalent to the Hashed Layout, But Is More Memory Efficient
Add asparse_hasheddictionary layout, that is functionally equivalent to thehashedlayout, but is more memory efficient. It uses about twice as less memory at the cost of slower value retrieval. #6894 (Azat Khuzhin)
Why it matters
Thesparse_hashed layout reduces memory usage by approximately half compared to the hashed layout, making it suitable for scenarios where memory constraints are critical. This optimization comes with a trade-off of slower value retrieval, allowing users to balance between memory consumption and query performance.How to use it
To use thesparse_hashed layout, define your dictionary with the layout = 'sparse_hashed' parameter instead of hashed. This enables the new memory-efficient dictionary implementation while maintaining compatibility with existing dictionary usage.