diff --git a/NPLib/MUST2/TMust2Physics.cxx b/NPLib/MUST2/TMust2Physics.cxx index 3f821da0f868d37cb68a75e28b9c590f8fdef767..931366732898498c51470bbabedc7b47b16380d9 100644 --- a/NPLib/MUST2/TMust2Physics.cxx +++ b/NPLib/MUST2/TMust2Physics.cxx @@ -32,6 +32,8 @@ using namespace MUST2_LOCAL; #include "RootInput.h" #include "RootOutput.h" #include "TAsciiFile.h" +#include "NPOptionManager.h" + // ROOT #include "TChain.h" /////////////////////////////////////////////////////////////////////////// @@ -1028,6 +1030,10 @@ void TMust2Physics::ReadConfiguration(string Path){ InitializeStandardParameter(); ReadAnalysisConfig(); + + if(NPOptionManager::getInstance()->GetGenerateHistoOption()){ + m_Spectra = new TMust2Spectra(m_NumberOfTelescope); + } cout << endl << "/////////////////////////////" << endl << endl; diff --git a/NPLib/MUST2/TMust2Spectra.cxx b/NPLib/MUST2/TMust2Spectra.cxx index cd5067cba8d31c4eb1807bbec79cb1c76b1424d1..7ce34589471e11193e148479f5b1910a587e1d4e 100644 --- a/NPLib/MUST2/TMust2Spectra.cxx +++ b/NPLib/MUST2/TMust2Spectra.cxx @@ -36,15 +36,19 @@ //////////////////////////////////////////////////////////////////////////////// TMust2Spectra::TMust2Spectra(unsigned int NumberOfTelescope){ if(NPOptionManager::getInstance()->GetVerboseLevel()>0) - cout << "TMust2Spectra : Initalising control spectra for " - << fNumberOfTelescope - << " Telescopes" << endl ; + cout << "************************************************" << endl + << "TMust2Spectra : Initalising control spectra for " + << NumberOfTelescope << " Telescopes" << endl + << "************************************************" << endl ; fNumberOfTelescope = NumberOfTelescope; fStripX=128; fStripY=128; fPadSili=16; fCrystalCsI=16; + + InitRawSpectra(); + InitPreTreatedSpectra(); } //////////////////////////////////////////////////////////////////////////////// @@ -87,20 +91,20 @@ void TMust2Spectra::InitRawSpectra(){ name = Form("MM%d_CSI_T_RAW", i+1); AddHisto2D(name, name, fCrystalCsI, 1, fCrystalCsI+1, 512, 0, 8192, "MUST2/RAW/CSIT"); - // STRX_MULT - name = Form("MM%d_STRX_MULT", i+1); + // STRX_RAW_MULT + name = Form("MM%d_STRX_RAW_MULT", i+1); AddHisto1D(name, name, fStripX, 1, fStripX+1, "MUST2/RAW/MULT"); - // STRY_MULT - name = Form("MM%d_STRY_MULT", i+1); + // STRY_RAW_MULT + name = Form("MM%d_STRY_RAW_MULT", i+1); AddHisto1D(name, name, fStripX, 1, fStripX+1, "MUST2/RAW/MULT"); - // SILI_MULT - name = Form("MM%d_SILI_MULT", i+1); + // SILI_RAW_MULT + name = Form("MM%d_SILI_RAW_MULT", i+1); AddHisto1D(name, name, fPadSili, 1, fPadSili+1, "MUST2/RAW/MULT"); - // CSI_MULT - name = Form("MM%d_CSI_MULT", i+1); + // CSI_RAW_MULT + name = Form("MM%d_CSI_RAW_MULT", i+1); AddHisto1D(name, name, fCrystalCsI, 1, fCrystalCsI+1, "MUST2/RAW/MULT"); } // end loop on number of detectors } @@ -142,20 +146,20 @@ void TMust2Spectra::InitPreTreatedSpectra() name = Form("MM%d_CSI_T_CAL", i+1); AddHisto2D(name, name, fCrystalCsI, 1, fCrystalCsI+1, 500, 0, 50, "MUST2/CAL/CSIT"); - // STRX_MULT - name = Form("MM%d_STRX_MULT", i+1); + // STRX_CAL_MULT + name = Form("MM%d_STRX_CAL_MULT", i+1); AddHisto1D(name, name, fStripX, 1, fStripX+1, "MUST2/CAL/MULT"); - // STRY_MULT - name = Form("MM%d_STRY_MULT", i+1); + // STRY_CAL_MULT + name = Form("MM%d_STRY_CAL_MULT", i+1); AddHisto1D(name, name, fStripX, 1, fStripX+1, "MUST2/CAL/MULT"); - // SILI_MULT - name = Form("MM%d_SILI_MULT", i+1); + // SILI_CAL_MULT + name = Form("MM%d_SILI_CAL_MULT", i+1); AddHisto1D(name, name, fPadSili, 1, fPadSili+1, "MUST2/CAL/MULT"); - // CSI_MULT - name = Form("MM%d_CSI_MULT", i+1); + // CSI_CAL_MULT + name = Form("MM%d_CSI_CAL_MULT", i+1); AddHisto1D(name, name, fCrystalCsI, 1, fCrystalCsI+1, "MUST2/CAL/MULT"); } // end loop on number of detectors