BmnRoot 26.10.0-233-gb9bbe585
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
compareA.C File Reference
#include "BmnDataReader.h"
#include "CbmStsTrack.h"
#include "CbmVertex.h"
#include <TBox.h>
#include <TCanvas.h>
#include <TGaxis.h>
#include <TH1D.h>
#include <TH2D.h>
#include <TPad.h>
#include <TPaveText.h>
#include <TString.h>
#include <TStyle.h>
#include <TTreeReaderArray.h>
#include <TTreeReaderValue.h>
#include <iomanip>
#include <iostream>
Include dependency graph for compareA.C:

Go to the source code of this file.

Macros

#define BMN_FILELIST_NA   "/home/igor/bmnroot/align_new/cfg/run8/7466ev0p3.noa_rlerr.list"
#define BMN_FILELIST_A   "/home/igor/bmnroot/align_new/cfg/run8/7466ev0p3.manual.list"
#define RES_X   1920
#define RES_Y   1440
#define PADS_X   2
#define PADS_Y   2

Enumerations

enum  eAligned { kNA = 0 , kAL = 1 }
enum  eCmpHists {
  kTracksCount , kVertexCount , kTracksChi2perNDF , kVertexZ ,
  kVertexX , kVertexY , kVertexXYbefore , kVertexXYafter ,
  kCount
}

Functions

int compareA (int argc=0, char **argv=nullptr)
 Judge alignment quality by comparing reconstruction before and after.

Variables

static constexpr const char * BMN_RESULT_PDF {"/home/igor/bmnroot/align_new/reports/MMCP-2026/Proceedings/Polev_MMCP2026/QualityExample.pdf"}
constexpr Int_t kDEF {kAL}
constexpr Int_t kSEC {kNA}
constexpr const Int_t histPos [eCmpHists::kCount][2]

Macro Definition Documentation

◆ BMN_FILELIST_A

#define BMN_FILELIST_A   "/home/igor/bmnroot/align_new/cfg/run8/7466ev0p3.manual.list"

Definition at line 34 of file compareA.C.

Referenced by compareA().

◆ BMN_FILELIST_NA

#define BMN_FILELIST_NA   "/home/igor/bmnroot/align_new/cfg/run8/7466ev0p3.noa_rlerr.list"

Definition at line 33 of file compareA.C.

Referenced by compareA().

◆ PADS_X

#define PADS_X   2

Definition at line 42 of file compareA.C.

Referenced by compareA(), compareS(), histo(), histoGL(), and review().

◆ PADS_Y

#define PADS_Y   2

Definition at line 43 of file compareA.C.

Referenced by compareA(), compareS(), histo(), histoGL(), and review().

◆ RES_X

#define RES_X   1920

Definition at line 40 of file compareA.C.

Referenced by compareA(), compareS(), histo(), histoGL(), and review().

◆ RES_Y

#define RES_Y   1440

Definition at line 41 of file compareA.C.

Referenced by compareA(), compareS(), histo(), histoGL(), and review().

Enumeration Type Documentation

◆ eAligned

enum eAligned
Enumerator
kNA 0 
kAL 1 

Definition at line 45 of file compareA.C.

◆ eCmpHists

enum eCmpHists
Enumerator
kTracksCount 
kVertexCount 
kTracksChi2perNDF 
kVertexZ 
kVertexX 
kVertexY 
kVertexXYbefore 
kVertexXYafter 
kCount 

Definition at line 52 of file compareA.C.

Function Documentation

◆ compareA()

int compareA ( int argc = 0,
char ** argv = nullptr )

Reads two datasets - the same events reconstructed with and without the alignment applied - and overlays what should improve: track count, chi2 per NDF, vertex position and its spread. The alignment is good when the aligned sample yields more tracks with a tighter chi2 and a sharper vertex.

Configuration is compile-time, through the defines at the top of the file (BMN_FILELIST_NA and BMN_FILELIST_A name the two datasets).

Parameters
argcunused, kept so the macro can be invoked with ROOT's argument passing convention
argvunused, see argc
Returns
0 on success, non-zero if either dataset could not be read

Definition at line 94 of file compareA.C.

References TPaveText::AddText(), BMN_FILELIST_A, BMN_FILELIST_NA, BMN_RESULT_PDF, TPad::cd(), TBox::Draw(), TH1::Draw(), TPad::Draw(), TPaveText::Draw(), TH1::Fill(), TH2::Fill(), TAxis::GetBinLowEdge(), TAxis::GetBinWidth(), TH1::GetMean(), TH1::GetStdDev(), TH1::GetXaxis(), TH1::GetYaxis(), histPos, i, kAL, kCount, kDEF, kNA, kSEC, kTracksChi2perNDF, kTracksCount, kVertexCount, kVertexX, kVertexXYafter, kVertexXYbefore, kVertexY, kVertexZ, PADS_X, PADS_Y, RES_X, RES_Y, TPad::SaveAs(), TH1::Scale(), TH1::SetBarOffset(), TH1::SetBarWidth(), TAxis::SetBinLabel(), TCanvas::SetCanvasSize(), TAttFill::SetFillColor(), TAttFill::SetFillStyle(), TAttAxis::SetLabelSize(), TAttLine::SetLineColor(), TAttLine::SetLineWidth(), TGaxis::SetMaxDigits(), TAxis::SetRangeUser(), TH1::SetStats(), TH1::StatOverflows(), and vertex().

Here is the call graph for this function:

Variable Documentation

◆ BMN_RESULT_PDF

const char* BMN_RESULT_PDF {"/home/igor/bmnroot/align_new/reports/MMCP-2026/Proceedings/Polev_MMCP2026/QualityExample.pdf"}
staticconstexpr

Definition at line 37 of file compareA.C.

Referenced by compareA().

◆ histPos

const Int_t histPos[eCmpHists::kCount][2]
constexpr
Initial value:
{
{1, 0},
{1, 1},
{0, 0},
{0, 1},
{-1, -1},
{-1, -1},
{-1, -1},
{-1, -1}
}

Definition at line 66 of file compareA.C.

Referenced by compareA().

◆ kDEF

Int_t kDEF {kAL}
constexpr

Definition at line 50 of file compareA.C.

Referenced by compareA().

◆ kSEC

Int_t kSEC {kNA}

Definition at line 50 of file compareA.C.

Referenced by compareA().