Public Member Functions | |
L1EmEtScaleOnlineProd (const edm::ParameterSet &) | |
virtual boost::shared_ptr < L1CaloEtScale > | newObject (const std::string &objectKey) |
~L1EmEtScaleOnlineProd () |
Description: <one line="" class="" summary>="">
Implementation: <Notes on="" implementation>="">
Definition at line 34 of file L1EmEtScaleOnlineProd.cc.
L1EmEtScaleOnlineProd::L1EmEtScaleOnlineProd | ( | const edm::ParameterSet & | iConfig | ) |
Definition at line 59 of file L1EmEtScaleOnlineProd.cc.
: L1ConfigOnlineProdBase< L1EmEtScaleRcd, L1CaloEtScale >( iConfig ) { //the following line is needed to tell the framework what // data is being produced //now do what ever other initialization is needed }
L1EmEtScaleOnlineProd::~L1EmEtScaleOnlineProd | ( | ) |
Definition at line 70 of file L1EmEtScaleOnlineProd.cc.
{ // do anything here that needs to be done at desctruction time // (e.g. close files, deallocate resources etc.) }
boost::shared_ptr< L1CaloEtScale > L1EmEtScaleOnlineProd::newObject | ( | const std::string & | objectKey | ) | [virtual] |
Implements L1ConfigOnlineProdBase< L1EmEtScaleRcd, L1CaloEtScale >.
Definition at line 79 of file L1EmEtScaleOnlineProd.cc.
References l1t::OMDSReader::basicQuery(), L1ConfigOnlineProdBase< L1EmEtScaleRcd, L1CaloEtScale >::m_omdsReader, l1t::OMDSReader::singleAttribute(), and GOODCOLL_filter_cfg::thresh.
{ using namespace edm::es; // ~~~~~~~~~ Cut values ~~~~~~~~~ std::vector< std::string > queryStrings ; queryStrings.push_back( "ET_GEV_BIN_LOW_0"); queryStrings.push_back( "ET_GEV_BIN_LOW_1"); queryStrings.push_back( "ET_GEV_BIN_LOW_2"); queryStrings.push_back( "ET_GEV_BIN_LOW_3"); queryStrings.push_back( "ET_GEV_BIN_LOW_4"); queryStrings.push_back( "ET_GEV_BIN_LOW_5"); queryStrings.push_back( "ET_GEV_BIN_LOW_6"); queryStrings.push_back( "ET_GEV_BIN_LOW_7"); queryStrings.push_back( "ET_GEV_BIN_LOW_8"); queryStrings.push_back( "ET_GEV_BIN_LOW_9"); queryStrings.push_back( "ET_GEV_BIN_LOW_10"); queryStrings.push_back( "ET_GEV_BIN_LOW_11"); queryStrings.push_back( "ET_GEV_BIN_LOW_12"); queryStrings.push_back( "ET_GEV_BIN_LOW_13"); queryStrings.push_back( "ET_GEV_BIN_LOW_14"); queryStrings.push_back( "ET_GEV_BIN_LOW_15"); queryStrings.push_back( "ET_GEV_BIN_LOW_16"); queryStrings.push_back( "ET_GEV_BIN_LOW_17"); queryStrings.push_back( "ET_GEV_BIN_LOW_18"); queryStrings.push_back( "ET_GEV_BIN_LOW_19"); queryStrings.push_back( "ET_GEV_BIN_LOW_20"); queryStrings.push_back( "ET_GEV_BIN_LOW_21"); queryStrings.push_back( "ET_GEV_BIN_LOW_22"); queryStrings.push_back( "ET_GEV_BIN_LOW_23"); queryStrings.push_back( "ET_GEV_BIN_LOW_24"); queryStrings.push_back( "ET_GEV_BIN_LOW_25"); queryStrings.push_back( "ET_GEV_BIN_LOW_26"); queryStrings.push_back( "ET_GEV_BIN_LOW_27"); queryStrings.push_back( "ET_GEV_BIN_LOW_28"); queryStrings.push_back( "ET_GEV_BIN_LOW_29"); queryStrings.push_back( "ET_GEV_BIN_LOW_30"); queryStrings.push_back( "ET_GEV_BIN_LOW_31"); queryStrings.push_back( "ET_GEV_BIN_LOW_32"); queryStrings.push_back( "ET_GEV_BIN_LOW_33"); queryStrings.push_back( "ET_GEV_BIN_LOW_34"); queryStrings.push_back( "ET_GEV_BIN_LOW_35"); queryStrings.push_back( "ET_GEV_BIN_LOW_36"); queryStrings.push_back( "ET_GEV_BIN_LOW_37"); queryStrings.push_back( "ET_GEV_BIN_LOW_38"); queryStrings.push_back( "ET_GEV_BIN_LOW_39"); queryStrings.push_back( "ET_GEV_BIN_LOW_40"); queryStrings.push_back( "ET_GEV_BIN_LOW_41"); queryStrings.push_back( "ET_GEV_BIN_LOW_42"); queryStrings.push_back( "ET_GEV_BIN_LOW_43"); queryStrings.push_back( "ET_GEV_BIN_LOW_44"); queryStrings.push_back( "ET_GEV_BIN_LOW_45"); queryStrings.push_back( "ET_GEV_BIN_LOW_46"); queryStrings.push_back( "ET_GEV_BIN_LOW_47"); queryStrings.push_back( "ET_GEV_BIN_LOW_48"); queryStrings.push_back( "ET_GEV_BIN_LOW_49"); queryStrings.push_back( "ET_GEV_BIN_LOW_50"); queryStrings.push_back( "ET_GEV_BIN_LOW_51"); queryStrings.push_back( "ET_GEV_BIN_LOW_52"); queryStrings.push_back( "ET_GEV_BIN_LOW_53"); queryStrings.push_back( "ET_GEV_BIN_LOW_54"); queryStrings.push_back( "ET_GEV_BIN_LOW_55"); queryStrings.push_back( "ET_GEV_BIN_LOW_56"); queryStrings.push_back( "ET_GEV_BIN_LOW_57"); queryStrings.push_back( "ET_GEV_BIN_LOW_58"); queryStrings.push_back( "ET_GEV_BIN_LOW_59"); queryStrings.push_back( "ET_GEV_BIN_LOW_60"); queryStrings.push_back( "ET_GEV_BIN_LOW_61"); queryStrings.push_back( "ET_GEV_BIN_LOW_62"); queryStrings.push_back( "ET_GEV_BIN_LOW_63"); const l1t::OMDSReader::QueryResults scaleKeyResults = m_omdsReader.singleAttribute( objectKey ) ; l1t::OMDSReader::QueryResults scaleResults = m_omdsReader.basicQuery( queryStrings, "CMS_GT", "L1T_SCALE_CALO_ET_THRESHOLD", "L1T_SCALE_CALO_ET_THRESHOLD.ID", m_omdsReader.basicQuery( "L1T_SCALE_CALO_ET_THRESHOLD_ID", "CMS_RCT", "L1CALOEMETTHRESH", "L1CALOEMETTHRESH.NAME", scaleKeyResults )); if( scaleResults.queryFailed() || scaleResults.numberRows() != 1 ) // check query successful { edm::LogError( "L1-O2O" ) << "Problem with L1EmEtScale key." ; return boost::shared_ptr< L1CaloEtScale >() ; } std::vector<double> m_thresholds; for( std::vector< std::string >::iterator thresh = queryStrings.begin(); thresh != queryStrings.end(); ++thresh) { float tempScale; scaleResults.fillVariable(*thresh,tempScale); m_thresholds.push_back(tempScale); } l1t::OMDSReader::QueryResults lsbResults = m_omdsReader.basicQuery("INPUTLSB", "CMS_RCT", "L1CALOEMETTHRESH", "L1CALOEMETTHRESH.NAME", scaleKeyResults ); if( lsbResults.queryFailed() || lsbResults.numberRows() != 1 ) // check query successful { edm::LogError( "L1-O2O" ) << "Problem with L1EmEtScale key." ; return boost::shared_ptr< L1CaloEtScale >() ; } double m_lsb; lsbResults.fillVariable(m_lsb); // std::cout << " input lsb " << m_lsb <<std::endl; //~~~~~~~~~ Instantiate new L1EmEtScale object. ~~~~~~~~~ // Default objects for Lindsey return boost::shared_ptr< L1CaloEtScale >( new L1CaloEtScale( m_lsb,m_thresholds ) ); }