FEDRA emulsion software from the OPERA Collaboration
|
helper class for access to the run data More...
#include <EdbRunTracking.h>
Public Member Functions | |
void | CheckZ (float &z1, float &z2) |
EdbRunTracking () | |
EdbRunTracking (const char *fname) | |
EdbRunTracking (EdbRun *run) | |
int | ExtrapolateCond (EdbScanCond &inputcond, int flag, EdbScanCond &outputcond) |
int | FindBestCandidate (EdbPattern &fndbt, EdbSegP &fnd, EdbPattern &cnd, float wmin, float wmindegrad, float chi2max) |
int | FindCandidateMT (EdbPattern &fnds1, EdbPattern &fnds2, EdbSegP &fnd) |
int | FindCandidates (EdbSegP &spred, EdbPattern &fndbt, EdbPattern &fnds1, EdbPattern &fnds2) |
int | FindCompliments (EdbSegP &s, EdbPattern &pat, TObjArray &found, float chi2max, TArrayF &chiarr) |
int | FindPrediction (EdbSegP &spred, EdbSegP &fndbt, EdbSegP &fnds1, EdbSegP &fnds2, EdbSegP &snewpred) |
int | FindTrack (EdbTrackP &pred, EdbTrackP &found, EdbPlateP &plate) |
bool | GetSBtreeEntry (int entry, TTree &tsbt) |
int | GetSegmentsForDB (EdbSegP &s, EdbSegP &s1, EdbSegP &s2) |
void | Print () |
void | Set0 () |
void | SetCondBT (EdbScanCond &cond) |
void | SetCondMT (EdbScanCond &cond) |
void | SetPred (const EdbSegP &pred) |
void | TransformFromPlateRS (EdbPlateP &plate) |
int | UpdateFlag (int flag, int status) |
bool | UpdateSBtree (TTree &tsbt, int idp[4], int idf[4]) |
virtual | ~EdbRunTracking () |
![]() | |
bool | AcceptRawSegment (EdbView *view, int ud, EdbSegP &segP, int side, int entry) |
bool | AddRWDToRun (char *rwdname, const char *options="") |
void | AddSegmentCut (int ud, int xi, float min[5], float max[5]) |
void | AddSegmentCut (int ud, int xi, float var[10]) |
void | AddSegmentCut (int xi, const char *cutline) |
void | ApplyCorrections (const EdbView &view, EdbSegment &s, const int rs) |
float | CalculateSegmentChi2 (EdbSegment *seg, float sx, float sy, float sz) |
int | Check0Views (EdbPattern &pat, int thres=1) |
int | CheckEmptyViews (EdbPattern &pat) |
float | CheckMeanSegsPerView (EdbPattern &pat) |
void | CheckRunLine () |
TH2F * | CheckUpDownOffsets () |
void | CheckViewSize () |
void | CheckViewStep () |
void | CheckViewStep (int ud) |
void | ClearCuts () |
bool | CopyRawDataXY (float x0, float y0, float dR, const char *file) |
EdbRunAccess () | |
EdbRunAccess (const char *fname) | |
EdbRunAccess (EdbRun *run) | |
void | FillDZMaps () |
int | FillVP () |
int | FirstArea () const |
EdbScanCond * | GetCond (int ud) |
EdbSegmentCut * | GetCut (int ud, int i) |
float | GetCutGR () const |
int | GetEntryXY (int ud, float x, float y) |
EdbLayer * | GetLayer (int id) |
EdbScanCond * | GetMakeCond (int ud) |
EdbLayer * | GetMakeLayer (int id) |
Int_t | GetNareas () |
Int_t | GetNviewsPerArea () |
int | GetPatternData (EdbPattern &pat, int side, int nviews, TArrayI &srt, int &nrej) |
int | GetPatternDataForPrediction (int id, int side, EdbPattern &pat) |
int | GetPatternXY (EdbSegP &s, int side, EdbPattern &pat, float rmin=200) |
int | GetPatternXYcut (EdbSegP &s, int side, EdbPattern &pat, float dr, float dt) |
EdbSegment * | GetRawSegment (EdbView &v, int sid, int rs=0) |
EdbSegment * | GetRawSegment (int vid, int sid, int rs=0) |
EdbSegment * | GetRawSegmentN (int vid, int sid, int rs=0) |
float | GetRawSegmentPix (EdbSegment *seg) |
EdbRun * | GetRun () const |
int | GetViewsArea (int ud, TArrayI &entr, float xmin, float xmax, float ymin, float ymax) |
int | GetViewsArea (int ud, TArrayI &entr, int area, float &xmin, float &xmax, float &ymin, float &ymax) |
int | GetViewsAreaMarg (int ud, TArrayI &entr, int area, float xmarg, float ymarg) |
int | GetViewsXY (int ud, TArrayI &entr, float x, float y, float r=200.) |
int | GetVolumeArea (EdbPatternsVolume &vol, int area) |
int | GetVolumeData (EdbPatternsVolume &vol, int nviews, TArrayI &srt, int &nrej) |
int | GetVolumeXY (EdbSegP &s, EdbPatternsVolume &vol) |
EdbPattern * | GetVP (int ud) const |
void | GuessNviewsPerArea () |
bool | InitRun (const char *runfile=0, bool do_update=false) |
bool | InitRunFromRWC (char *rwcname, bool bAddRWD=true, const char *options="") |
int | LastArea () const |
int | NCuts (int ud) |
float | OverlapX (int ud) |
float | OverlapY (int ud) |
bool | PassCuts (int ud, EdbSegment &seg) |
void | Print () |
void | PrintStat () |
void | ReadVAfile () |
float | SegmentWeight (const EdbSegment &s) |
void | Set0 () |
void | SetCond (int ud, EdbScanCond &cond) |
void | SetCutBottom (int ud, float wmin) |
void | SetCutLeft (int ud, float wmin) |
void | SetCutRight (int ud, float wmin) |
void | SetCutTop (int ud, float wmin) |
void | SetPixelCorrection (const char *str) |
bool | SetSegmentAtExternalSurface (EdbSegment *seg, int side) |
int | ViewSide (const EdbView *view) const |
float | ViewX (const EdbView *view) const |
float | ViewY (const EdbView *view) const |
virtual | ~EdbRunAccess () |
Static Public Member Functions | |
static void | CloseSBtree (TTree *tree) |
static int | GetBTHoles (int flag) |
static int | GetMTHoles (int flag) |
static TTree * | InitSBtree (const char *file_name="sbt.root", const char *mode="RECREATE") |
Public Attributes | |
Float_t | eChi2MaxBT |
(1.5) maximum chi2 accepted between prediction and basetrack candidates More... | |
Float_t | eChi2MaxMT |
(1.6) maximum chi2 accepted between prediction and microtrack candidates More... | |
EdbScanCond | eCondBT |
conditions for basetracks More... | |
EdbScanCond | eCondMT |
conditions for microtracks More... | |
Float_t | eDegradPos |
SigmaX = SigmaX(0) + degradPos * mth. More... | |
Float_t | eDegradSlope |
SigmaTX = SigmaTX(0) + degradSlope * bth. More... | |
Float_t | eDeltaR |
(20) More... | |
Float_t | eDeltaRview |
(400) More... | |
Float_t | eDeltaTheta |
(0.15) slope acceptance More... | |
Int_t | eIdf [4] |
Int_t | eIdp [4] |
to read from sbt More... | |
EdbSegP | eNext |
next prediction More... | |
EdbSegP | ePred |
prediction More... | |
bool | ePredictionScan |
if true use GetPatternDataForPrediction( spred.ID(), side, pat ); in FindCandidates (default is false) More... | |
Float_t | ePreliminaryChi2MaxMT |
(1.6) / microtracks and basetracks selection More... | |
Float_t | ePreliminaryPulsMinMT |
(6) _ preliminary cuts to microtracks candidates for More... | |
Float_t | ePulsMinBT |
(18) More... | |
Float_t | ePulsMinDegradBT |
(0) More... | |
Float_t | ePulsMinDegradMT |
(0) More... | |
Float_t | ePulsMinMT |
(10) mimimal number of grains accepted to select microtracks More... | |
EdbSegP | eS |
EdbSegP | eS1 |
EdbPattern | eS1cnd |
microtrack candidates passed all cuts More... | |
EdbPattern | eS1pre |
the result of the preliminary selection of microtracks More... | |
EdbSegP | eS2 |
found segments More... | |
EdbPattern | eS2cnd |
EdbPattern | eS2pre |
EdbPattern | eScnd |
basetracks candidates passed all cuts More... | |
EdbPattern | eSpre |
preliminary selected basetracks More... | |
Int_t | eStatus |
-1-nothing, 0-bt, 1-mt1, 2-mt2 More... | |
![]() | |
Int_t | eAFID |
if =1 - use affine transformations of the fiducial marks More... | |
Int_t | eCLUST |
1-use clusters, 0 - do not More... | |
Int_t | eDoPixelCorr |
apply or not pix/mic correction when read data (default is 0) More... | |
Bool_t | eDoViewAnalysis |
fill or not the histograms for optional view analysis More... | |
TGraph2D * | eGraphDZ [3] |
keep the base/layer1/layer2 thickness calculated using eZ1/eZ2/eZ3/eZ4 for each view More... | |
TGraph2D * | eGraphZ [4] |
keep z1/z2/z3/z4 surfaces using eZ1/eZ2/eZ3/eZ4 for each view More... | |
TCut | eHeaderCut |
header cut to be applied in run initialization More... | |
EdbH2 | eHViewXY [3] |
XY segments distribution in a view local coords. More... | |
Bool_t | eInvertSides |
0 -do nothing, 1-invert sides More... | |
Float_t | ePixelCorrX |
pixel/micron correction factor to be applied for data More... | |
Float_t | ePixelCorrY |
Int_t | eTracking |
to test tracking alorithm: -1-ignored(def),0/1 - trackings to accept More... | |
Bool_t | eUseDensityAsW |
in case of LASSO tracking possible to use eSigmaY as eW More... | |
Bool_t | eUseExternalSurface |
if true - set segment position corrisponding to the very external cluster More... | |
Int_t | eWeightAlg |
0-puls, 1 - density(former eUseDensityAsW), 2-Likelyhood (eSigmaX) More... | |
helper class for access to the run data
|
inline |
|
inline |
|
inline |
|
virtual |
void EdbRunTracking::CheckZ | ( | float & | z1, |
float & | z2 | ||
) |
|
static |
int EdbRunTracking::ExtrapolateCond | ( | EdbScanCond & | inputcond, |
int | flag, | ||
EdbScanCond & | outputcond | ||
) |
TODO: tuning the dependency of sigma
NOTED by Artem: when we do jumping we have no "holes" stored in the flag, so this function do not
extrapolate errors correctly so one had to encrease the acceptance manually,
possible solution can be to add total plates number before the last found
track into the flag and use it only for extrapolatio
int EdbRunTracking::FindBestCandidate | ( | EdbPattern & | fndbt, |
EdbSegP & | fnd, | ||
EdbPattern & | cnd, | ||
float | wmin, | ||
float | wmindegrad, | ||
float | chi2max | ||
) |
int EdbRunTracking::FindCandidateMT | ( | EdbPattern & | fnds1, |
EdbPattern & | fnds2, | ||
EdbSegP & | fnd | ||
) |
int EdbRunTracking::FindCandidates | ( | EdbSegP & | spred, |
EdbPattern & | fndbt, | ||
EdbPattern & | fnds1, | ||
EdbPattern & | fnds2 | ||
) |
Find microtracks and basetracks for the prediction segment "spred"
Selection criteria:
1) select all microtracks with (puls >= ePreliminaryPulsMinMT) (6) and (chi2 < ePreliminaryChi2MaxMT) for both side
2) select all basetracks by using the selected microtracks, with (chi2_bt < eChi2MaxBT)
Microtracks and basetracks in output are sorted according to chi2 (ascending order = the first one is the best one)
Input:
spred - track prediction
Output:
fnds1 - microtracks having puls>=ePreliminaryPulsMinMT and chi2<ePreliminaryChi2MaxMT
in the top side of the emulsion plate
fnds2 - microtracks having puls>=ePreliminaryPulsMinMT and chi2<ePreliminaryChi2MaxMT
in the bottom side of the emulsion plate
fndbt - basetracks built from the microtracks and (chi2_bt < eChi2MaxBT)
int EdbRunTracking::FindCompliments | ( | EdbSegP & | s, |
EdbPattern & | pat, | ||
TObjArray & | found, | ||
float | chi2max, | ||
TArrayF & | chiarr | ||
) |
int EdbRunTracking::FindPrediction | ( | EdbSegP & | spred, |
EdbSegP & | fndbt, | ||
EdbSegP & | fnds1, | ||
EdbSegP & | fnds2, | ||
EdbSegP & | snewpred | ||
) |
Select the best (micro or base) track matching with the prediction
and prepare for a new search.
Selection criteria: 1) Call FindCandidates having the list of basetrack and microtrack candidates
2) Call FindCandidateBT which looks for the best basetrack, if any
3) If no basetrack is found, call FindCandidateMT which looks fot the best microtrack, if any.
Microtracks accepted shold satisfy the following cut: (puls >= ePulsMinMT) (10) and (chi2 < eChi2MaxMT)
Input:
spred - track prediction
Output:
look for tracks in this plate
track - input track in brick RS - will be updated on output
plate - all plate parameters including affine transformation plate-to-brick
|
inlinestatic |
|
inlinestatic |
bool EdbRunTracking::GetSBtreeEntry | ( | int | entry, |
TTree & | tsbt | ||
) |
return s,s1,s2 if status >=0, create fake microtracks if necessary
for fakes: seg->GetPuls(), seg->GetVolume(), seg->GetSigmaX() //0, 0, -1
|
static |
void EdbRunTracking::Print | ( | ) |
void EdbRunTracking::Set0 | ( | ) |
|
inline |
|
inline |
int EdbRunTracking::UpdateFlag | ( | int | flag, |
int | status | ||
) |
status: -1 -found nothing, 0-bt, 1-mt1, 2-mt2
bool EdbRunTracking::UpdateSBtree | ( | TTree & | tsbt, |
int | idp[4], | ||
int | idf[4] | ||
) |
Float_t EdbRunTracking::eChi2MaxBT |
(1.5) maximum chi2 accepted between prediction and basetrack candidates
Float_t EdbRunTracking::eChi2MaxMT |
(1.6) maximum chi2 accepted between prediction and microtrack candidates
EdbScanCond EdbRunTracking::eCondBT |
conditions for basetracks
EdbScanCond EdbRunTracking::eCondMT |
conditions for microtracks
Float_t EdbRunTracking::eDegradPos |
SigmaX = SigmaX(0) + degradPos * mth.
Float_t EdbRunTracking::eDegradSlope |
SigmaTX = SigmaTX(0) + degradSlope * bth.
Float_t EdbRunTracking::eDeltaR |
(20)
Float_t EdbRunTracking::eDeltaRview |
(400)
Float_t EdbRunTracking::eDeltaTheta |
(0.15) slope acceptance
Int_t EdbRunTracking::eIdf[4] |
Int_t EdbRunTracking::eIdp[4] |
to read from sbt
EdbSegP EdbRunTracking::eNext |
next prediction
EdbSegP EdbRunTracking::ePred |
prediction
bool EdbRunTracking::ePredictionScan |
if true use GetPatternDataForPrediction( spred.ID(), side, pat ); in FindCandidates (default is false)
Float_t EdbRunTracking::ePreliminaryChi2MaxMT |
(1.6) / microtracks and basetracks selection
Float_t EdbRunTracking::ePreliminaryPulsMinMT |
(6) _ preliminary cuts to microtracks candidates for
Float_t EdbRunTracking::ePulsMinBT |
(18)
Float_t EdbRunTracking::ePulsMinDegradBT |
(0)
Float_t EdbRunTracking::ePulsMinDegradMT |
(0)
Float_t EdbRunTracking::ePulsMinMT |
(10) mimimal number of grains accepted to select microtracks
EdbSegP EdbRunTracking::eS |
EdbSegP EdbRunTracking::eS1 |
EdbPattern EdbRunTracking::eS1cnd |
microtrack candidates passed all cuts
EdbPattern EdbRunTracking::eS1pre |
the result of the preliminary selection of microtracks
EdbSegP EdbRunTracking::eS2 |
found segments
EdbPattern EdbRunTracking::eS2cnd |
EdbPattern EdbRunTracking::eS2pre |
EdbPattern EdbRunTracking::eScnd |
basetracks candidates passed all cuts
EdbPattern EdbRunTracking::eSpre |
preliminary selected basetracks
Int_t EdbRunTracking::eStatus |
-1-nothing, 0-bt, 1-mt1, 2-mt2