1#include "KVDataAnalyser.h"
2#define KVDSTTreeConverter_cxx
4#include "KVINDRADSTConverter.h"
5#include "KVUserAnalysisOptionList.h"
7#include <KVReconNucTrajectory.h>
113 auto idtelescope_code =
idcode[i];
118 else if (
icou[i] < 10)
120 else if (
icou[i] >= 10) {
130 else if (
icou[i] > 9) {
146 else if (
icou[i] > 9) {
156 else if (
icou[i] > 9) {
179 "Got no detector with id=%d cou=%d mod=%d z=%d a=%d ecod=%d ener=%f",
187 if (node->GetNTrajForwards() > 1) {
190 traj = (
KVGeoDNTrajectory*)node->GetTrajectories()->FindObjectWithMethod(
"4",
"GetN");
192 traj = (
KVGeoDNTrajectory*)node->GetTrajectories()->FindObjectWithMethod(
"2",
"GetN");
202 if (!node->GetTrajectories()) {
203 Warning(
"Process",
"node %s has no trajectories", node->GetName());
206 TIter next_id(rtraj->GetIDTelescopes());
209 if (idt->
GetIDCode() == idtelescope_code)
break;
211 if (!idt || idt->
GetIDCode() != idtelescope_code) {
220 nuc->SetReconstructionTrajectory(rtraj);
241 auto idr = nuc->GetIdentificationResult(1);
242 idr->IDattempted =
true;
244 idr->SetIDType(idt->
GetType());
257 idr->Aident = (
a[i] > 0);
258 if (idr->Aident) idr->PID =
a_indra[i];
267 nuc->SetIsIdentified();
268 nuc->SetIdentification(idr, idt);
271 nuc->SetIsCalibrated();
272 nuc->SetECode(
ecode[i]);
273 nuc->SetEnergy(
ener[i]);
274 nuc->GetAnglesFromReconstructionTrajectory();
276 nuc->SetParameter(
"INDRA.EPHOS",
de1[i]);
279 nuc->SetParameter(
"INDRA.ECHIO",
de1[i]);
280 nuc->SetParameter(
"INDRA.DE_MYLAR",
de_mylar[i]);
283 nuc->SetParameter(
"INDRA.ESI",
de2[i]);
286 nuc->SetParameter(
"INDRA.ECSI",
de3[i]);
292 nuc->SetIsUncalibrated();
char * Form(const char *fmt,...)
virtual Bool_t IsCalled(const Char_t *name) const
virtual const Char_t * GetType() const
void WriteBatchInfo(TTree *)
void CommitRunfile(const Char_t *type, Int_t run, TFile *file)
TFile * NewRunfile(const Char_t *type, Int_t run)
Base class for detector geometry description.
KVGroup * GetGroup() const
KVGeoDetectorNode * GetNode()
void Clear(Option_t *opt="")
static void MakeEventBranch(TTree *tree, const TString &branchname, T &event, Int_t bufsize=10000000)
KVNameValueList * GetParameters() const
void SetParameter(const Char_t *name, ValType value) const
Path taken by particles through multidetector geometry.
KVSeqCollection * GetTrajectories() const
const KVGeoDNTrajectory * GetTrajectoryForReconstruction(const KVGeoDNTrajectory *t, const KVGeoDetectorNode *n) const
Base class for all detectors or associations of detectors in array which can identify charged particl...
virtual UShort_t GetIDCode()
KVINDRADBRun * GetRun(Int_t run) const
TTreeReaderArray< Float_t > si_gg
TTreeReaderArray< Int_t > z
TTreeReaderArray< Float_t > de1
virtual void Begin(TTree *tree)
TTreeReaderArray< Float_t > z_indra
virtual Bool_t Process(Long64_t entry)
bool stopped_in_si75(int i)
TTreeReaderValue< Int_t > npart_traite
pointer to the analyzed TTree or TChain
TTreeReaderArray< Float_t > a_indra
KVINDRADetector * get_si75(int i)
bool stopped_in_sili(int i)
KVINDRADetector * get_phos(int i)
bool stopped_in_si(int i)
KVINDRADetector * get_csi(int i)
bool stopped_in_ci(int i)
virtual void SlaveBegin(TTree *tree)
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
TTreeReaderArray< Float_t > csi_r
KVINDRADetector * get_sili(int i)
bool stopped_in_csi(int i)
TTreeReaderArray< Float_t > csi_l
bool stopped_in_phos(int i)
TTreeReaderArray< Float_t > ci_pg
TTreeReaderArray< Int_t > icou
KVINDRADetector * get_ci(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
virtual void SlaveTerminate()
TTreeReaderArray< Float_t > de2
TTreeReaderArray< Int_t > ecode
KVINDRADetector * get_si(int i)
Base class for detectors of INDRA array.
KVINDRADetector * GetChIo() const
KVHashList * GetListOfPhoswich() 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
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.
virtual TObject * First() const
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