#include <CosSim.hpp>
Inheritance diagram for lemur::cluster::CosSim:
Public Member Functions | |
CosSim (const lemur::api::Index &dbIndex) | |
Precomputes the idf values for the collection. | |
virtual | ~CosSim () |
clean up | |
void | weigh (ClusterRep *rep) const |
normalize rep with idf values. | |
double | similarity (const ClusterRep *vec1, const ClusterRep *vec2) const |
compute similarity between two reps. | |
const double * | idfValues () const |
return pointer to precomputed idf values. | |
Protected Attributes | |
const lemur::api::Index & | ind |
double * | idfV |
int | numDocs |
int | numTerms |
|
Precomputes the idf values for the collection. Cosine similarity method. Precomputes the idf values for the collection. |
|
clean up
|
|
return pointer to precomputed idf values.
|
|
compute similarity between two reps.
Implements lemur::cluster::SimilarityMethod. |
|
normalize rep with idf values.
Reimplemented from lemur::cluster::SimilarityMethod. |
|
|
|
|
|
|
|
|