Calculate cosine similarity between sparse vectors without converting to dense.
sparse_cosine_similarity(
X: SparseValues,
Y: List[SparseValues],
) -> np.ndarray| Name | Type | Description |
|---|---|---|
X* | SparseValues | A single sparse vector |
Y* | List[SparseValues] | A list of sparse vectors |