1 #include "KVDataAnalyser.h"
2 #define KVDSTTreeConverter_cxx
4 #include "KVINDRADSTConverter.h"
5 #include "KVUserAnalysisOptionList.h"
7 #include <KVReconNucTrajectory.h>
76 KVDetector* CSI =
nullptr;
114 auto idtelescope_code =
idcode[i];
119 else if (
icou[i] < 10)
121 else if (
icou[i] >= 10) {
131 else if (
icou[i] > 9) {
147 else if (
icou[i] > 9) {
157 else if (
icou[i] > 9) {
180 "Got no detector with id=%d cou=%d mod=%d z=%d a=%d ecod=%d ener=%f",
184 auto node = det->GetNode();
188 if (node->GetNTrajForwards() > 1) {
191 traj = (
KVGeoDNTrajectory*)node->GetTrajectories()->FindObjectWithMethod(
"4",
"GetN");
193 traj = (
KVGeoDNTrajectory*)node->GetTrajectories()->FindObjectWithMethod(
"2",
"GetN");
203 if (!node->GetTrajectories()) {
204 Warning(
"Process",
"node %s has no trajectories", node->GetName());
206 auto rtraj = (
KVReconNucTrajectory*)det->GetGroup()->GetTrajectoryForReconstruction(traj, node);
207 TIter next_id(rtraj->GetIDTelescopes());
210 if (idt->
GetIDCode() == idtelescope_code)
break;
212 if (!idt || idt->
GetIDCode() != idtelescope_code) {
221 nuc->SetReconstructionTrajectory(rtraj);
242 auto idr = nuc->GetIdentificationResult(1);
243 idr->IDattempted =
true;
245 idr->SetIDType(idt->
GetType());
258 idr->Aident = (
a[i] > 0);
259 if (idr->Aident) idr->PID =
a_indra[i];
268 nuc->SetIsIdentified();
269 nuc->SetIdentification(idr, idt);
272 nuc->SetIsCalibrated();
273 nuc->SetECode(
ecode[i]);
274 nuc->SetEnergy(
ener[i]);
275 nuc->GetAnglesFromReconstructionTrajectory();
277 nuc->SetParameter(
"INDRA.EPHOS",
de1[i]);
280 nuc->SetParameter(
"INDRA.ECHIO",
de1[i]);
281 nuc->SetParameter(
"INDRA.DE_MYLAR",
de_mylar[i]);
284 nuc->SetParameter(
"INDRA.ESI",
de2[i]);
287 nuc->SetParameter(
"INDRA.ECSI",
de3[i]);
293 nuc->SetIsUncalibrated();
char * Form(const char *fmt,...)
virtual const Char_t * GetType() const
virtual Bool_t IsCalled(const Char_t *name) const
void WriteBatchInfo(TTree *)
void CommitRunfile(const KVString &type, const run_index_t &run, TFile *file)
TFile * NewRunfile(const KVString &type, const run_index_t &run)
KVNameValueList * GetParameters() const
static void MakeEventBranch(TTree *tree, const TString &branchname, T &event, Int_t bufsize=10000000)
void Clear(Option_t *opt="") override
void SetParameter(const Char_t *name, ValType value) const
const KVDBRunFile & GetDBRunFile(const run_index_t &r) const
Path taken by particles through multidetector geometry.
Base class for all detectors or associations of detectors in array which can identify charged particl...
virtual UShort_t GetIDCode()
TTreeReaderArray< Float_t > si_gg
TTreeReaderArray< Int_t > z
TTreeReaderArray< Float_t > de1
TTreeReaderArray< Float_t > z_indra
KVINDRADetector * get_sili(int i)
bool stopped_in_si75(int i)
TTreeReaderValue< Int_t > npart_traite
pointer to the analyzed TTree or TChain
TTreeReaderArray< Float_t > a_indra
bool stopped_in_sili(int i)
KVINDRADetector * get_ci(int i)
bool stopped_in_si(int i)
void SlaveBegin(TTree *tree) override
bool stopped_in_ci(int i)
TTreeReaderArray< Float_t > de5
TTreeReaderArray< Float_t > de3
TTreeReaderArray< Float_t > de4
TTreeReaderArray< Float_t > ci_gg
TTreeReaderArray< Float_t > si_pg
TTreeReaderArray< Int_t > a
void Terminate() override
TTreeReaderArray< Float_t > csi_r
KVINDRADetector * get_phos(int i)
bool stopped_in_csi(int i)
KVINDRADetector * get_si75(int i)
Bool_t Process(Long64_t entry) override
TTreeReaderArray< Float_t > csi_l
bool stopped_in_phos(int i)
TTreeReaderArray< Float_t > ci_pg
TTreeReaderArray< Int_t > icou
KVINDRADetector * get_csi(int i)
TTreeReaderArray< Float_t > de_mylar
TTreeReaderArray< Int_t > imod
KVReconstructedEvent * the_event
TTreeReaderArray< Int_t > idcode
TTreeReaderArray< Float_t > ener
TTreeReader fReader
the tree reader
void SlaveTerminate() override
KVINDRADetector * get_si(int i)
TTreeReaderArray< Float_t > de2
TTreeReaderArray< Int_t > ecode
void Begin(TTree *tree) override
Base class for detectors of INDRA array.
KVINDRADetector * GetChIo() const
@ ID_CI_SI75
particle identified in ChIo-Si75 etalon telescope
@ ID_SI_CSI
particle identified in Si-CsI telescope
@ ID_NEUTRON
'neutron' discriminated by coherency between CsI and Si-CsI identifications
@ ID_CI_SI
particle identified in ChIo-Si telescope
@ ID_CI_SI_COHERENCY
particle identified in ChIo-Si telescope in coincidence with light particle identified in CsI
@ ID_STOPPED_IN_FIRST_STAGE
particle stopped in first detector of telescope, only minimum Z can be estimated
@ ID_CSI_PSA
particle identified in CsI detector by pulse shape analysis
@ ID_PHOSWICH
particle identified in phoswich (campaigns 1-3)
@ NO_IDENTIFICATION
no identification either attempted or available for particle
@ ID_CI_COHERENCY
particle stopped in ChIo revealed by coherency tests (Zmin)
@ ID_CI_MULTIHIT
particles stopped in multiple Si (ring<10) or CsI (ring>9) behind same ChIo, bad identification
@ ID_CSI_FRAGMENT
particle partially identified in CsI detector, with Z greater than identifiable
@ ID_GAMMA
'gamma' particle detected in CsI
@ ID_CSI_MASS_OUT_OF_RANGE
particle partially identified in CsI detector, mass out of range of apparent Z (pile-up?...
@ ID_SI75_SILI
particle identified in Si75-SiLi etalon telescope
@ ID_CI_CSI
particle identified in ChIo-CsI telescope
virtual KVINDRADetector * GetDetectorByType(UInt_t cou, UInt_t mod, UInt_t type) const
const KVSeqCollection * GetListOfPhoswich() const
virtual void SetParameters(UInt_t n, Bool_t physics_parameters_only=kFALSE)
static KVMultiDetArray * MakeMultiDetector(const Char_t *dataset_name, Int_t run=-1, TString classname="KVMultiDetArray")
void IncrementValue(const Char_t *name, value_type value)
void SetParameter(const Char_t *name, ValType value) const
Path through detector array used to reconstruct detected particle.
Event containing KVReconstructedNucleus nuclei reconstructed from hits in detectors.
Handle list of options and input parameters for user analyis .
TString GetOpt(const Char_t *opt) const
void ParseOptions(const KVString &optlist)
virtual Bool_t IsEmpty() const
const char * GetName() const override
const char * GetTitle() const override
virtual void Warning(const char *method, const char *msgfmt,...) const
virtual void Error(const char *method, const char *msgfmt,...) const
virtual void Info(const char *method, const char *msgfmt,...) const
const char * GetOption() const override
EEntryStatus SetLocalEntry(Long64_t entry)
Int_t Write(const char *name=nullptr, Int_t option=0, Int_t bufsize=0) const override