Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // calculate distances and sort them
- std::vector<Clustering::ClusterDistance> distances;
- distances.resize(previousClusters.size()*currentClusters.size());
- for (int i=0; i< previousClusters.size(); i++)
- {
- for(int j=0; j < currentClusters.size(); j++)
- {
- int index = j + i * currentClusters.size();
- distances[index] = Clustering::ClusterDistance( cv::norm(previousClusters[i].m_Properties.m_Center - currentClusters[j].m_Properties.m_Center), previousClusters[i], currentClusters[j] );
- }
- }
Add Comment
Please, Sign In to add comment