Skip to content
Snippets Groups Projects
Commit 7cfc5054 authored by matta's avatar matta
Browse files

* Adding config file reading for SSSD on same model as MUST2

 - User can now edit a ConfigSSSD.dat file in order to disable channel
parent 6764ffe1
No related branches found
No related tags found
No related merge requests found
...@@ -43,7 +43,7 @@ TMust2Physics::TMust2Physics() ...@@ -43,7 +43,7 @@ TMust2Physics::TMust2Physics()
EventData = new TMust2Data ; EventData = new TMust2Data ;
PreTreatedData = new TMust2Data ; PreTreatedData = new TMust2Data ;
EventPhysics = this ; EventPhysics = this ;
NumberOfTelescope = 0 ; NumberOfTelescope = 0 ;
m_MaximumStripMultiplicityAllowed = 0 ; m_MaximumStripMultiplicityAllowed = 0 ;
m_StripEnergyMatchingTolerance = 0 ; m_StripEnergyMatchingTolerance = 0 ;
// ReadAnalysisConfig(); // ReadAnalysisConfig();
...@@ -1055,12 +1055,9 @@ void TMust2Physics::ReadConfiguration(string Path) ...@@ -1055,12 +1055,9 @@ void TMust2Physics::ReadConfiguration(string Path)
} }
} }
// InitializeStandardParameter();
// ReadAnalysisConfig();
} }
InitializeStandardParameter(); InitializeStandardParameter();
ReadAnalysisConfig(); ReadAnalysisConfig();
cout << endl << "/////////////////////////////" << endl << endl; cout << endl << "/////////////////////////////" << endl << endl;
......
This diff is collapsed.
...@@ -33,60 +33,90 @@ using namespace std ; ...@@ -33,60 +33,90 @@ using namespace std ;
#include "../include/VDetector.h" #include "../include/VDetector.h"
#include "../include/CalibrationManager.h" #include "../include/CalibrationManager.h"
class TSSSDPhysics : public TObject, public NPA::VDetector class TSSSDPhysics : public TObject, public NPA::VDetector
{ {
public: // Constructor and Destructor public: // Constructor and Destructor
TSSSDPhysics(); TSSSDPhysics();
~TSSSDPhysics(); ~TSSSDPhysics();
public: // Calibrated Data
vector<UShort_t> DetectorNumber ; public: // Calibrated Data
vector<UShort_t> StripNumber ; vector<UShort_t> DetectorNumber;
vector<Double_t> Energy ; vector<UShort_t> StripNumber;
vector<Double_t> Time ; vector<Double_t> Energy;
vector<Double_t> Time;
public: // inherrited from VDetector public: // inherrited from VDetector
// Read stream at ConfigFile to pick-up parameters of detector (Position,...) using Token // Read stream at ConfigFile to pick-up parameters of detector (Position,...) using Token
void ReadConfiguration(string) ; void ReadConfiguration(string);
// Add Parameter to the CalibrationManger
// Add Parameter to the CalibrationManger void AddParameterToCalibrationManager();
void AddParameterToCalibrationManager() ;
// Activated associated Branches and link it to the private member DetectorData address // Activated associated Branches and link it to the private member DetectorData address
// In this method mother Branches (Detector) AND daughter leaf (fDetector_parameter) have to be activated // In this method mother Branches (Detector) AND daughter leaf (fDetector_parameter) have to be activated
void InitializeRootInput() ; void InitializeRootInput();
// Create associated branches and associated private member DetectorPhysics address
void InitializeRootOutput();
// Create associated branches and associated private member DetectorPhysics address // This method is called at each event read from the Input Tree. Aime is to build treat Raw dat in order to extract physical parameter.
void InitializeRootOutput() ; void BuildPhysicalEvent();
// This method is called at each event read from the Input Tree. Aime is to build treat Raw dat in order to extract physical parameter.
void BuildPhysicalEvent() ;
// Same as above, but only the simplest event and/or simple method are used (low multiplicity, faster algorythm but less efficient ...).
// This method aimed to be used for analysis performed during experiment, when speed is requiered.
// NB: This method can eventually be the same as BuildPhysicalEvent.
void BuildSimplePhysicalEvent();
// Those two method all to clear the Event Physics or Data
void ClearEventPhysics() {Clear();}
void ClearEventData() {EventData->Clear();}
public: // Specific to SSSD
// Clear The PreTeated object
void ClearPreTreatedData() {PreTreatedData->Clear();}
// Same as above, but only the simplest event and/or simple method are used (low multiplicity, faster algorythm but less efficient ...). // Remove bad channel, calibrate the data and apply threshold
// This method aimed to be used for analysis performed during experiment, when speed is requiered. void PreTreat();
// NB: This method can eventually be the same as BuildPhysicalEvent.
void BuildSimplePhysicalEvent() ; // Initialize the standard parameter for analysis
// ie: all channel enable, maximum multiplicity for strip = number of telescope
// Those two method all to clear the Event Physics or Data void InitializeStandardParameter();
void ClearEventPhysics() {Clear();}
void ClearEventData() {EventData->Clear();} // Read the user configuration file; if no file found, load standard one
void ReadAnalysisConfig();
private: // Data not writted in the tree
int NumberOfDetector ;//!
TSSSDData* EventData ;//! private: // Data not written in the tree
TSSSDPhysics* EventPhysics ;//! int NumberOfDetector; //!
TSSSDData* EventData; //!
void Clear(); TSSSDData* PreTreatedData; //!
void Clear(const Option_t*) {}; TSSSDPhysics* EventPhysics; //!
double E_Threshold; //!
double Pedestal_Threshold; //!
private: // Map of activated Channel
map< int, vector<bool> > ChannelStatus;//!
public: // Return True if the channel is activated
// bool IsValidChannel(int DetectorNbr, int StripNbr) ;
void Clear();
void Clear(const Option_t*) {};
ClassDef(TSSSDPhysics,1) // SSSDPhysics structure ClassDef(TSSSDPhysics,1) // SSSDPhysics structure
}; };
namespace LOCAL
{
double fSi_E( TSSSDData* EventData , int i );
double fSi_T( TSSSDData* EventData , int i );
}
#endif #endif
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