23 #define LOG cout << "TCS::NotMatch:     " 
   55    p_NumberLeading1 = parameter(
"InputWidth1").value();
 
   56    p_NumberLeading2 = parameter(
"InputWidth2").value();
 
   57    if(parameter(
"MaxTob1").
value() > 0) p_NumberLeading1 = parameter(
"MaxTob1").value();
 
   58    if(parameter(
"MaxTob2").
value() > 0) p_NumberLeading2 = parameter(
"MaxTob2").value();
 
   59    for(
unsigned int i=0; 
i<numberOutputBits(); ++
i) {
 
   60     p_MinET1[
i] = parameter(
"MinET1",
i).value();
 
   61     p_MinET2[
i] = parameter(
"MinET2",
i).value();
 
   65     p_EtaMin1[
i] = parameter(
"EtaMin1",
i).value();
 
   66     p_EtaMin2[
i] = parameter(
"EtaMin2",
i).value();
 
   70     p_EtaMax1[
i] = parameter(
"EtaMax1",
i).value();
 
   71     p_EtaMax2[
i] = parameter(
"EtaMax2",
i).value();
 
   75     p_DRCut[
i]   = parameter(
"DRCut",
i).value();
 
   86                              const std::vector<TCS::TOBArray *> & output,
 
   89    if( input.size() == 2) {
 
   92       for(
unsigned int i=0; 
i<numberOutputBits(); ++
i) {
 
   93           bool all_unmatched = 
true;
 
   94       std::vector<GenericTOB*> unmatched_tobs;
 
   96            tob1 != input[0]->end() && 
distance(input[0]->
begin(), tob1) < p_NumberLeading1;
 
   99             if (p_NumberLeading1 < input[0]->
size()) { 
 
  101                if ((*tob1)->Et() == (*tob1_plus1)->Et() && 
distance(input[0]->
begin(), tob1) == p_NumberLeading1 - 1) { 
 
  102                   for(
unsigned int i=0; 
i<numberOutputBits(); ++
i) {
 
  103                      output[
i]->setAmbiguityFlag(
true); 
 
  107             if( 
parType_t((*tob1)->Et()) <= p_MinET1[
i]) 
continue; 
 
  108             if( 
parType_t(std::abs((*tob1)->eta())) > p_EtaMax1[
i] ) 
continue; 
 
  109             if( 
parType_t(std::abs((*tob1)->eta())) < p_EtaMin1[
i] ) 
continue; 
 
  113                  tob2 != input[1]->end() && 
distance(input[1]->
begin(), tob2) < p_NumberLeading2 && 
matched != true ;
 
  115                if( 
parType_t((*tob2)->Et()) <= p_MinET2[
i]) 
continue; 
 
  116                if( 
parType_t(std::abs((*tob2)->eta())) > p_EtaMax2[
i] ) 
continue; 
 
  117                if( 
parType_t(std::abs((*tob2)->eta())) < p_EtaMin2[
i] ) 
continue; 
 
  119                deltaR2 = calcDeltaR2BW( *tob1, *tob2 );
 
  124             if(not 
matched) unmatched_tobs.push_back(*tob1);
 
  125             all_unmatched = all_unmatched and not 
matched;
 
  127        const bool accept = all_unmatched and unmatched_tobs.size()>0;
 
  130            for(
const auto tob : unmatched_tobs)
 
  136       TCS_EXCEPTION(
"NotMatch alg must have  2 inputs, but got " << input.size());
 
  144                              const std::vector<TCS::TOBArray *> & output,
 
  147    if( input.size() == 2) {
 
  150       for(
unsigned int i=0; 
i<numberOutputBits(); ++
i) { 
 
  151        bool all_unmatched = 
true;
 
  152        std::vector<GenericTOB*> unmatched_tobs;
 
  154            tob1 != input[0]->end() && 
distance(input[0]->
begin(), tob1) < p_NumberLeading1;
 
  157             if( 
parType_t((*tob1)->Et()) <= p_MinET1[
i]) 
continue; 
 
  158             if( 
parType_t(std::abs((*tob1)->eta())) > p_EtaMax1[
i] ) 
continue; 
 
  159             if( 
parType_t(std::abs((*tob1)->eta())) < p_EtaMin1[
i] ) 
continue; 
 
  163                  tob2 != input[1]->end() && 
distance(input[1]->
begin(), tob2) < p_NumberLeading2 && 
matched != true ;
 
  165                if( 
parType_t((*tob2)->Et()) <= p_MinET2[
i]) 
continue; 
 
  166                if( 
parType_t(std::abs((*tob2)->eta())) > p_EtaMax2[
i] ) 
continue; 
 
  167                if( 
parType_t(std::abs((*tob2)->eta())) < p_EtaMin2[
i] ) 
continue; 
 
  169                deltaR2 = calcDeltaR2( *tob1, *tob2 );
 
  174             if(not 
matched) unmatched_tobs.push_back(*tob1);
 
  175             all_unmatched = all_unmatched and not 
matched;
 
  177        const bool accept = all_unmatched and unmatched_tobs.size()>0;
 
  180            for(
const auto tob : unmatched_tobs)
 
  186       TCS_EXCEPTION(
"NotMatch alg must have  2 inputs, but got " << input.size());