00001 #include "DQM/SiStripCommissioningClients/interface/DaqScopeModeHistograms.h"
00002 #include "CondFormats/SiStripObjects/interface/DaqScopeModeAnalysis.h"
00003 #include "DataFormats/SiStripCommon/interface/SiStripConstants.h"
00004 #include "DataFormats/SiStripCommon/interface/SiStripEnumsAndStrings.h"
00005 #include "DQM/SiStripCommissioningAnalysis/interface/DaqScopeModeAlgorithm.h"
00006 #include "DQM/SiStripCommissioningSummary/interface/SummaryGenerator.h"
00007 #include "FWCore/MessageLogger/interface/MessageLogger.h"
00008 #include <iostream>
00009 #include <sstream>
00010 #include <iomanip>
00011
00012 using namespace std;
00013 using namespace sistrip;
00014
00015
00017 DaqScopeModeHistograms::DaqScopeModeHistograms( DQMOldReceiver* mui )
00018 : CommissioningHistograms( mui, sistrip::DAQ_SCOPE_MODE ),
00019 factory_( new Factory )
00020 {
00021 cout << endl
00022 << "[DaqScopeModeHistograms::" << __func__ << "]"
00023 << " Constructing object...";
00024 }
00025
00026
00028 DaqScopeModeHistograms::~DaqScopeModeHistograms() {
00029 cout << endl
00030 << "[DaqScopeModeHistograms::" << __func__ << "]"
00031 << " Constructing object...";
00032 }
00033
00034
00036 void DaqScopeModeHistograms::histoAnalysis( bool debug ) {
00037
00038
00039 data_.clear();
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080 }
00081
00082
00084 void DaqScopeModeHistograms::createSummaryHisto( const sistrip::Monitorable& histo,
00085 const sistrip::Presentation& type,
00086 const std::string& directory,
00087 const sistrip::Granularity& gran ) {
00088 cout << endl
00089 << "[DaqScopeModeHistograms::" << __func__ << "]";
00090
00091
00092 sistrip::View view = SiStripEnumsAndStrings::view(directory);
00093 if ( view == sistrip::UNKNOWN_VIEW ) { return; }
00094
00095
00096 histoAnalysis( false );
00097
00098
00099 factory_->init( histo, type, view, directory, gran );
00100 uint32_t xbins = factory_->extract( data_ );
00101
00102
00103 TH1* summary = histogram( histo, type, view, directory, xbins );
00104
00105
00106 factory_->fill( *summary );
00107
00108 }