Cosine similarity
Distance Metric
Overview
Use casemeasuring similarity between vectors in high-dimensional spaces
Also see
Alternative to
Knowledge graph stats
Claims17
Avg confidence92%
Avg freshness100%
Last updatedUpdated 18h ago
WikidataQ2997501
Trust distribution
100% unverified
Cosine similarity
concept
Measure of similarity between vectors based on the cosine of the angle between them.
Compare with...mathematical range
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| -1 to 1 | ○Unverified | High | Fresh | 1 |
primary use case
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| measuring similarity between vectors in high-dimensional spaces | ○Unverified | High | Fresh | 1 |
implemented in
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| scikit-learn | ○Unverified | High | Fresh | 1 |
| NumPy | ○Unverified | High | Fresh | 1 |
| TensorFlow | ○Unverified | High | Fresh | 1 |
based on
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| dot product and vector magnitudes | ○Unverified | High | Fresh | 1 |
invariant to
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| vector magnitude | ○Unverified | High | Fresh | 1 |
commonly used in
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| natural language processing | ○Unverified | High | Fresh | 1 |
| information retrieval | ○Unverified | High | Fresh | 1 |
| recommendation systems | ○Unverified | High | Fresh | 1 |
alternative to
| Value | Trust | Confidence | Freshness | Sources |
|---|---|---|---|---|
| Euclidean distance | ○Unverified | Moderate | Fresh | 1 |
| Manhattan distance | ○Unverified | Moderate | Fresh | 1 |
| Jaccard similarity | ○Unverified | Moderate | Fresh | 1 |