What does lut_work_const do?
calvinmccarter opened this issue · 1 comments
I see that lut_work_const can take the value of 2, 4, -1 (which seems to mean \infty). Does this make a difference to accuracy, and if so, which was the final version that I should use?
I had support for a k-sparse centroids at one point, as an intermediary between MADDNESS-PQ (block diagonal prototype matrix) and MADDNESS (dense prototype matrix). It made it so that this matrix was instead structured sparse, with 2 or 4 codebooks allowed to have nonzero values in any given dimension.
I didn't include this in the paper because I didn't have space and it complicated the story, but this would be useful if forming the prototype matrix were a bottleneck. This would be expected when the number of columns in B is large relative to the number of rows in A.
Also, for your other question regarding conditioning on the matrix B if it's known, I think you can just modify learn_mithral to also take in B, and then modify encoded_lstsq to predict AB instead of A. You'd get out the LUTs directly instead of the prototypes. Will take a little plumbing to get the relevant variables passed around, but that's the core of it.