The lightweight_coreset function should compute the distances in batches similar to greedy_coreset. Therefore a batch_size kwarg needs to be added and integrated into the function in the same manner. This keyword must also be added to LightweightCoreset (query strategy) and passed in the function call (similar to GreedyCoreset).
Motivation
This will reduce max memory used and, moreover, will align the lightweight and greedy coreset implementations.
Feature description
The
lightweight_coreset
function should compute the distances in batches similar togreedy_coreset
. Therefore a batch_size kwarg needs to be added and integrated into the function in the same manner. This keyword must also be added toLightweightCoreset
(query strategy) and passed in the function call (similar toGreedyCoreset
).Motivation
This will reduce max memory used and, moreover, will align the lightweight and greedy coreset implementations.
Addition comments
Everything that needs to be adapted is currently located under small_text.query_strategies.coresets.