torch-ash
torch-ash copied to clipboard
Question about Hashmap resizing.
Hi Dr. Dong @theNded Thanks for your amazing work and great project!
Here I have a question and looking forward your help : ) I noticed that HashEmbedding class disabled resizing to maintain a static embedding. Is it because the indices of the hashmap will change after resizing. If it is feasible to achieve dynamic embedding allocation during incremental mapping based on it. For example we explicitly allocate a embedding index to each grids like {grid_coor, embedding_idx}. When the capacity is less than we need, we extend the embeddings and resize the hashmap.