Concept Flow - Distance computation (distance.cdist)
Input: Two sets of points A and B
Select distance metric (e.g., Euclidean)
Compute pairwise distances between each point in A and each point in B
Output: Distance matrix with shape (len(A), len(B))
We start with two groups of points, pick a distance type, then calculate distances between every pair from the two groups, producing a matrix of distances.