DiskANN CalcDistByIDs returns early when all requested vectors are found in the coordinate cache, skipping the metric-specific distance
conversion.
As a result:
- COSINE similarity is returned with the wrong sign.
- INNER_PRODUCT conversion and norm rescaling are skipped.
- L2 and requests containing uncached vectors are unaffected.
DiskANN CalcDistByIDs returns early when all requested vectors are found in the coordinate cache, skipping the metric-specific distance
conversion.
As a result: