Skip to content
Snippets Groups Projects
Commit 2631abd3 authored by moukaddam's avatar moukaddam
Browse files

The low gain config variable is now set independantly for crystal or segment

parent e1a13f7a
No related branches found
No related tags found
No related merge requests found
......@@ -67,7 +67,8 @@ ClassImp(TGeTAMUPhysics)
void TGeTAMUPhysics::InitializeStandardParameter(){
//Set high gain as default
m_LowGainIsSet = false;
m_LowGainCryIsSet = false;
m_LowGainSegIsSet = false;
m_CryChannelStatus.clear() ;
m_SegChannelStatus.clear() ;
......@@ -126,9 +127,14 @@ void TGeTAMUPhysics::ReadAnalysisConfig(){
AnalysisConfigFile.ignore(numeric_limits<streamsize>::max(), '\n' );
}
else if (whatToDo== "LOW_GAIN_ENERGY") {
m_LowGainIsSet = true ;
cout << whatToDo << " " << m_LowGainIsSet << endl; // e.g. DataBuffer = CLOVER03
else if (whatToDo== "LOW_GAIN_ENERGY_CRY") {
m_LowGainCryIsSet = true ;
cout << whatToDo << " " << m_LowGainCryIsSet << endl; // e.g. DataBuffer = CLOVER03
}
else if (whatToDo== "LOW_GAIN_ENERGY_SEG") {
m_LowGainSegIsSet = true ;
cout << whatToDo << " " << m_LowGainSegIsSet << endl; // e.g. DataBuffer = CLOVER03
}
else if (whatToDo== "DISABLE_ALL") {
......@@ -347,13 +353,13 @@ double Eraw,Energy;
double Traw,Time;
int clover, crystal, segment;
if(m_LowGainIsSet)
if(m_LowGainCryIsSet)
mysizeE = m_EventData->GetMultiplicityCoreELowGain();
else
mysizeE = m_EventData->GetMultiplicityCoreE();
for(unsigned int i = 0 ; i < mysizeE ; i++){
if(m_LowGainIsSet){
if(m_LowGainCryIsSet){
clover = m_EventData->GetCoreCloverNbrELowGain(i);
crystal = m_EventData->GetCoreCrystalNbrELowGain(i);
Eraw = m_EventData->GetCoreEnergyLowGain(i);
......@@ -389,13 +395,13 @@ for(unsigned int i = 0 ; i < mysizeT ; i++){
}
}
if(m_LowGainIsSet)
if(m_LowGainSegIsSet)
mysizeE = m_EventData->GetMultiplicitySegmentELowGain();
else
mysizeE = m_EventData->GetMultiplicitySegmentE();
for(unsigned int i = 0 ; i < mysizeE ; i++){
if(m_LowGainIsSet){
if(m_LowGainSegIsSet){
clover = m_EventData->GetSegmentCloverNbrELowGain(i);
segment = m_EventData->GetSegmentSegmentNbrELowGain(i);
Eraw = m_EventData->GetSegmentEnergyLowGain(i);
......
......@@ -67,10 +67,6 @@ class TGeTAMUPhysics : public TObject, public NPL::VDetector{
// First argument is either 0 for Cry,1 Seg
bool IsValidChannel(const int& DetectorType, const int& detector , const int& channel) ;
// Return true if the energy is read from low gain channel
// First argument is either 0 for Cry,1 Seg
bool IsLowGainChannel(const int& DetectorType, const int& detector , const int& channel) ;
// Initialize the standard parameter for analysis
// ie: all channel enable, maximum multiplicity for strip = number of telescope
void InitializeStandardParameter();
......@@ -144,8 +140,9 @@ class TGeTAMUPhysics : public TObject, public NPL::VDetector{
double m_Seg_E_Threshold;
int m_Cry_E_Raw_Threshold;
int m_Seg_E_Raw_Threshold;
int m_AddBackMode;
bool m_LowGainIsSet;
int m_AddBackMode;
bool m_LowGainCryIsSet;
bool m_LowGainSegIsSet;
private: // use for anlysis
TLorentzVector m_GammaLV; //!
......
ConfigGeTamu
%%%%%%%% Default is high energy
%LOW_GAIN_ENERGY
LOW_GAIN_ENERGY_CRY
LOW_GAIN_ENERGY_SEG
%%%%%%%% Defective channels
%DISABLE_ALL CLOVER04
%DISABLE_CHANNEL CLOVER01_SEG01
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment