FEDRA emulsion software from the OPERA Collaboration
|
helper class for access to the run data More...
#include <EdbRunAccess.h>
Public Member Functions | |
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 () |
Public Attributes | |
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... | |
Private Attributes | |
EdbAffine2D * | eAffStage2Abs |
affine transformation extracted from Marks (if AFID=11) More... | |
EdbScanCond * | eCond [3] |
Float_t | eCutGR |
grain cut (chi) More... | |
TObjArray * | eCuts [3] |
arrays of cuts to be applied to segments More... | |
Int_t | eFirstArea |
Int_t | eLastArea |
EdbLayer * | eLayers [3] |
base(0),up(1),down(2) layers More... | |
Int_t | eNareas |
Int_t | eNviewsPerArea |
EdbRun * | eRun |
pointer to the run to be accessed More... | |
TString | eRunFileName |
TObjArray * | eViewCorr |
corrections obtained from the views alignment More... | |
Float_t | eViewXmax [3] |
Float_t | eViewXmin [3] |
Float_t | eViewYmax [3] |
Float_t | eViewYmin [3] |
EdbPattern * | eVP [3] |
Float_t | eXmax |
Float_t | eXmin |
Float_t | eXstep [3] |
Float_t | eYmax |
Float_t | eYmin |
Float_t | eYstep [3] |
helper class for access to the run data
//////////////////////////////////////////////////////////////////////// // EdbRunAccess // // OPERA data Run Access helper class // // ////////////////////////////////////////////////////////////////////////
EdbRunAccess::EdbRunAccess | ( | ) |
EdbRunAccess::EdbRunAccess | ( | const char * | fname | ) |
|
virtual |
bool EdbRunAccess::AddRWDToRun | ( | char * | rwdname, |
const char * | options = "" |
||
) |
void EdbRunAccess::AddSegmentCut | ( | int | layer, |
int | xi, | ||
float | min[5], | ||
float | max[5] | ||
) |
void EdbRunAccess::AddSegmentCut | ( | int | layer, |
int | xi, | ||
float | var[10] | ||
) |
void EdbRunAccess::AddSegmentCut | ( | int | xi, |
const char * | cutline | ||
) |
void EdbRunAccess::ApplyCorrections | ( | const EdbView & | view, |
EdbSegment & | s, | ||
const int | rs | ||
) |
rs=0 local view RS
rs==1 plate RS (use layer 1&2 information Note that the last emlink
should be done with all corrections off to get the consistent data here
rs==1 brick RS - use layer 0 info
float EdbRunAccess::CalculateSegmentChi2 | ( | EdbSegment * | seg, |
float | sx, | ||
float | sy, | ||
float | sz | ||
) |
assumed that clusters are attached to segments
int EdbRunAccess::Check0Views | ( | EdbPattern & | pat, |
int | thres = 1 |
||
) |
int EdbRunAccess::CheckEmptyViews | ( | EdbPattern & | pat | ) |
float EdbRunAccess::CheckMeanSegsPerView | ( | EdbPattern & | pat | ) |
void EdbRunAccess::CheckRunLine | ( | ) |
TH2F * EdbRunAccess::CheckUpDownOffsets | ( | ) |
void EdbRunAccess::CheckViewSize | ( | ) |
void EdbRunAccess::CheckViewStep | ( | ) |
void EdbRunAccess::CheckViewStep | ( | int | ud | ) |
assumed that in the tree (and in eVP) views are consecutive in the order of acquisition
void EdbRunAccess::ClearCuts | ( | ) |
bool EdbRunAccess::CopyRawDataXY | ( | float | x0, |
float | y0, | ||
float | dR, | ||
const char * | file | ||
) |
void EdbRunAccess::FillDZMaps | ( | ) |
fill DZ maps
int EdbRunAccess::FillVP | ( | ) |
fill patterns up/down with dummy segments with center of view coordinates
to profit of the pattern tools for the fast views selection
the convention is:
segp->ID() - tree entry number
segp->X() - coordinates in the external (brick) RS (after transformation)
segp->Y() - /
segp->Aid(areaID,viewID);
|
inline |
|
inline |
|
inline |
|
inline |
int EdbRunAccess::GetEntryXY | ( | int | ud, |
float | x, | ||
float | y | ||
) |
|
inline |
|
inline |
EdbLayer * EdbRunAccess::GetMakeLayer | ( | int | id | ) |
|
inline |
|
inline |
int EdbRunAccess::GetPatternData | ( | EdbPattern & | pat, |
int | side, | ||
int | nviews, | ||
TArrayI & | srt, | ||
int & | nrej | ||
) |
int EdbRunAccess::GetPatternDataForPrediction | ( | int | id, |
int | side, | ||
EdbPattern & | pat | ||
) |
get raw segments belonging to views having a given id (view->GetHeader()->GetTrack()) and a given side
the result is stored into an EdbPattern object
this routine is called by EdbRunTracking::FindCandidates and to select microtracks from a raw.root file
acquired for a specific prediction
Special case: if id=-1 - accept all views for the given side
int EdbRunAccess::GetPatternXY | ( | EdbSegP & | s, |
int | side, | ||
EdbPattern & | pat, | ||
float | rmin = 200 |
||
) |
int EdbRunAccess::GetPatternXYcut | ( | EdbSegP & | s0, |
int | side, | ||
EdbPattern & | pat, | ||
float | dr, | ||
float | dt | ||
) |
EdbSegment * EdbRunAccess::GetRawSegment | ( | EdbView & | view, |
int | sid, | ||
int | rs = 0 |
||
) |
EdbSegment * EdbRunAccess::GetRawSegment | ( | int | vid, |
int | sid, | ||
int | rs = 0 |
||
) |
EdbSegment * EdbRunAccess::GetRawSegmentN | ( | int | vid, |
int | sid, | ||
int | rs = 0 |
||
) |
float EdbRunAccess::GetRawSegmentPix | ( | EdbSegment * | seg | ) |
assumed that clusters are attached to segments
int EdbRunAccess::GetViewsArea | ( | int | ud, |
TArrayI & | entr, | ||
float | xmin, | ||
float | xmax, | ||
float | ymin, | ||
float | ymax | ||
) |
get all views in a given limits
int EdbRunAccess::GetViewsArea | ( | int | ud, |
TArrayI & | entr, | ||
int | area, | ||
float & | xmin, | ||
float & | xmax, | ||
float & | ymin, | ||
float & | ymax | ||
) |
get all views of "area" for the side "ud"; fill entr with the entries, calculate area limits
int EdbRunAccess::GetViewsAreaMarg | ( | int | ud, |
TArrayI & | entr, | ||
int | area, | ||
float | xmarg, | ||
float | ymarg | ||
) |
return area views with margins
ud: 0-base, 1-down, 2-up //TODO - to check this convention!
int EdbRunAccess::GetViewsXY | ( | int | ud, |
TArrayI & | entr, | ||
float | x, | ||
float | y, | ||
float | rv = 200. |
||
) |
int EdbRunAccess::GetVolumeArea | ( | EdbPatternsVolume & | vol, |
int | area | ||
) |
int EdbRunAccess::GetVolumeData | ( | EdbPatternsVolume & | vol, |
int | nviews, | ||
TArrayI & | srt, | ||
int & | nrej | ||
) |
int EdbRunAccess::GetVolumeXY | ( | EdbSegP & | s, |
EdbPatternsVolume & | vol | ||
) |
|
inline |
void EdbRunAccess::GuessNviewsPerArea | ( | ) |
bool EdbRunAccess::InitRun | ( | const char * | runfile = 0 , |
bool | do_update = false |
||
) |
bool EdbRunAccess::InitRunFromRWC | ( | char * | rwcname, |
bool | bAddRWD = true , |
||
const char * | options = "" |
||
) |
|
inline |
|
inline |
|
inline |
|
inline |
bool EdbRunAccess::PassCuts | ( | int | id, |
EdbSegment & | seg | ||
) |
void EdbRunAccess::Print | ( | ) |
void EdbRunAccess::PrintStat | ( | ) |
void EdbRunAccess::ReadVAfile | ( | ) |
float EdbRunAccess::SegmentWeight | ( | const EdbSegment & | s | ) |
void EdbRunAccess::Set0 | ( | ) |
|
inline |
void EdbRunAccess::SetCutBottom | ( | int | side, |
float | wmin | ||
) |
void EdbRunAccess::SetCutLeft | ( | int | side, |
float | wmin | ||
) |
void EdbRunAccess::SetCutRight | ( | int | side, |
float | wmin | ||
) |
void EdbRunAccess::SetCutTop | ( | int | side, |
float | wmin | ||
) |
void EdbRunAccess::SetPixelCorrection | ( | const char * | str | ) |
bool EdbRunAccess::SetSegmentAtExternalSurface | ( | EdbSegment * | seg, |
int | side | ||
) |
set the segment coordinates correspondent to the cluster coord with maximal Z
assumed that clusters are attached to segments
int EdbRunAccess::ViewSide | ( | const EdbView * | view | ) | const |
|
inline |
|
inline |
|
private |
affine transformation extracted from Marks (if AFID=11)
Int_t EdbRunAccess::eAFID |
if =1 - use affine transformations of the fiducial marks
Int_t EdbRunAccess::eCLUST |
1-use clusters, 0 - do not
|
private |
|
private |
grain cut (chi)
|
private |
arrays of cuts to be applied to segments
Int_t EdbRunAccess::eDoPixelCorr |
apply or not pix/mic correction when read data (default is 0)
Bool_t EdbRunAccess::eDoViewAnalysis |
fill or not the histograms for optional view analysis
|
private |
TGraph2D* EdbRunAccess::eGraphDZ[3] |
keep the base/layer1/layer2 thickness calculated using eZ1/eZ2/eZ3/eZ4 for each view
TGraph2D* EdbRunAccess::eGraphZ[4] |
keep z1/z2/z3/z4 surfaces using eZ1/eZ2/eZ3/eZ4 for each view
TCut EdbRunAccess::eHeaderCut |
header cut to be applied in run initialization
EdbH2 EdbRunAccess::eHViewXY[3] |
XY segments distribution in a view local coords.
Bool_t EdbRunAccess::eInvertSides |
0 -do nothing, 1-invert sides
|
private |
|
private |
base(0),up(1),down(2) layers
|
private |
|
private |
Float_t EdbRunAccess::ePixelCorrX |
pixel/micron correction factor to be applied for data
Float_t EdbRunAccess::ePixelCorrY |
|
private |
pointer to the run to be accessed
|
private |
Int_t EdbRunAccess::eTracking |
to test tracking alorithm: -1-ignored(def),0/1 - trackings to accept
Bool_t EdbRunAccess::eUseDensityAsW |
in case of LASSO tracking possible to use eSigmaY as eW
Bool_t EdbRunAccess::eUseExternalSurface |
if true - set segment position corrisponding to the very external cluster
|
private |
corrections obtained from the views alignment
|
private |
|
private |
|
private |
|
private |
|
private |
base/up/down side patterns (0,1,2) with the views coordinates inside
Int_t EdbRunAccess::eWeightAlg |
0-puls, 1 - density(former eUseDensityAsW), 2-Likelyhood (eSigmaX)
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |