Changeset: d9d3c84f0548 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d9d3c84f0548
Modified Files:
monetdb5/extras/rdf/rdfschema.c
Branch: rdf
Log Message:
Change the formula for computing the number of indirect references.
With considering the percentage of instances from the referring CS that has the
being-considered FK.
*= #ofRefereces_From_CSi / (Frequency_Of_CSi)
diffs (21 lines):
diff --git a/monetdb5/extras/rdf/rdfschema.c b/monetdb5/extras/rdf/rdfschema.c
--- a/monetdb5/extras/rdf/rdfschema.c
+++ b/monetdb5/extras/rdf/rdfschema.c
@@ -401,7 +401,8 @@ void getIRNums(CSrel *csrelSet, CSset *f
if (csrelSet[i].lstCnt[j] <
FILTER_THRESHOLD_FK_FOR_IR * freqCSset->items[freqId].support) continue;
#endif
if (freqId != i){ //Do not count
the self-reference
- curIRScores[freqId] +=
(lastIRScores[i] * (float)csrelSet[i].lstCnt[j]/(float)refCount[freqId] +
csrelSet[i].lstCnt[j]);
+ //curIRScores[freqId] +=
(lastIRScores[i] * (float)csrelSet[i].lstCnt[j]/(float)refCount[freqId]) +
csrelSet[i].lstCnt[j];
+ curIRScores[freqId] +=
(lastIRScores[i] * (float)csrelSet[i].lstCnt[j]/(float)refCount[freqId] *
(float)csrelSet[i].lstCnt[j]/freqCSset->items[i].support) +
csrelSet[i].lstCnt[j];
}
}
}
@@ -437,6 +438,7 @@ void updateFreqCStype(CSset *freqCSset,
if (curIRScores[i] < IR_DIMENSION_THRESHOLD) continue;
freqCSset->items[i].type = DIMENSIONCS;
+ //printf("A dimension CS with IR score = %f \n",
curIRScores[i]);
numDimensionCS++;
}
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list