src/Generic/PropTree/PropMatch.cpp
// defines P( target pred type | source pred type )

defines P( target pred type | source pred type )
defines P ( target pred type | source pred type )
float PropMatch::predicateTypeConfusionProb(const Predicate & src_pred, 
													  const Predicate & trg_pred) const {
	if( trg_pred.type() == src_pred.type() ) return 1.0f;
	ConfusionProbMatrix::const_iterator probEntryForward=
		_typeConfusionProbs->find(std::make_pair(src_pred.type(), trg_pred.type()));
	ConfusionProbMatrix::const_iterator probEntryBackward=
		_typeConfusionProbs->find(std::make_pair(trg_pred.type(), src_pred.type()));
	if (probEntryForward!=_typeConfusionProbs->end()) {
		return probEntryForward->second;
	} else if (probEntryBackward!=_typeConfusionProbs->end()) {
		return probEntryBackward->second;
	} else {
		return 0.10f;
	}
}
float PropMatch :: predicateTypeConfusionProb ( const Predicate & src_pred , const Predicate & trg_pred ) const { if ( trg_pred . type ( ) == src_pred . type ( ) ) return 1.0f ; ConfusionProbMatrix :: const_iterator probEntryForward = _typeConfusionProbs -> find ( std :: make_pair ( src_pred . type ( ) , trg_pred . type ( ) ) ) ; ConfusionProbMatrix :: const_iterator probEntryBackward = _typeConfusionProbs -> find ( std :: make_pair ( trg_pred . type ( ) , src_pred . type ( ) ) ) ; if ( probEntryForward != _typeConfusionProbs -> end ( ) ) { return probEntryForward -> second ; } else if ( probEntryBackward != _typeConfusionProbs -> end ( ) ) { return probEntryBackward -> second ; } else { return 0.10f ; } }
defines P( target pred type | source pred type )
defines P ( target pred type | source pred type )