51 int N_pt_above_cut = 0;
58 const HepMC::GenEvent* genEvt = (*itr);
60 for(
const auto& pitr: *genEvt){
61 if( std::abs(pitr->pdg_id()) != 25 )
continue;
63 auto decayVtx = pitr->end_vertex();
65 if (!decayVtx )
continue;
66 int n_daughters = decayVtx->particles_out_size();
67 if( n_daughters < 2 )
continue;
68 for (
const auto& child_mcpart: *decayVtx) {
69 if ( std::abs(child_mcpart->pdg_id()) != 5 )
continue;
70 if ( pitr->pdg_id() == 25 ) {
73 if( (pitr->momentum().perp() >=
m_Ptmin && pitr->momentum().perp() <
m_Ptmax ) ){
80 ATH_MSG_INFO(
"Found " << N_Higgs_all <<
" Higgs in event record" );
82 ATH_MSG_INFO(
"Found " << N_Higgs <<
" H -> b bbar decays" );
84 ATH_MSG_INFO(
"The number of Higgs with pt above " <<
m_Ptmin/1000.0 <<
" GeV/c is " << N_pt_above_cut );
86 if ( N_Higgs_all <= 0 ){
87 ATH_MSG_ERROR(
"No Higgs was found in a (presumably) Higgs event! Event is rejected." );
94 if( N_pt_above_cut >= 1 && N_Higgs >= 1) {
95 return StatusCode::SUCCESS;
99 setFilterPassed(
false);
100 return StatusCode::SUCCESS;