HIAnalysisTools


DerivarionFrameWork

HI MB Skimming Tool (Under Construction)

The Skimming Tool HIMBSkimmingTool.cxx is just the interface to run the HIEventSelector in the derivation framework, the default setup (today) require:

- Primary vertex

- MBTS timing

Implementation
from DerivationFrameworkHI.DerivationFrameworkHIConf import DerivationFramework__HIMBSkimmingTool
HIONSkimmingTool = DerivationFramework__HIMBSkimmingTool(name = "HIONSkimmingTool")
ToolSvc+=HIONSkimmingTool
Options
declareProperty("HIEventSelectorTool",m_selection_tool);

HI Event Selection Tool (Under Construction)

Here is where all the selection is done HIEventSelectionTool.cxx, Selection is done based on MBTS cut, vertex, tracks quality and soon Pileup rejection.

Implementation
from HIEventUtils.HIEventUtilsConf import HI__HIEventSelectionTool
HIEventSelector=HI__HIEventSelectionTool("HIEventSelector")
ToolSvc+=HIEventSelector
Options
declareProperty("TimeCut",m_timeCut=5.,"maximum DeltaT cut"); 
declareProperty("VertexSumPtCut",m_vtx_min_sumPt=5000.,"Minimum sum pT from good tracks for a good vertex"); NOT IMPLEMENTED YET
declareProperty("VertexNtrkCut",m_vtx_min_nTrk=2,"Minimum number  good tracks for a good vertex"); NOT IMPLEMENTED YET
declareProperty("RejectPileup",m_reject_pileup=false,"If true, cut on events w/ pileup applied"); NOT IMPLEMENTED YET
declareProperty("VertexSelectionTool",m_vertexSelectionTool);

HI Vertex Selection Tool (Working)

Here vertex and tracking selection is done, HIVertexSelectionTool.cxx. Vertex Sum pT and Nunmber of tracks Cuts needs to be conected with the Event Selector. By default the tool required a Primary Vertex and MaxAbsZ is set to 150mm, MinNTrk and MinRmsPt are set to -1 (turn off).

Implementation
from HIEventUtils.HIEventUtilsConf import HI__HIVertexSelectionTool
HIVertexSelector=HI__HIVertexSelectionTool("HIVertexSelector")
ToolSvc+=HIVertexSelector
Options
declareProperty( "RequirePrimary", m_requirePrimary, "Require the vertex to have type PriVtx");
declareProperty( "MaxAbsZ", m_maxAbsZ, "Maximum absolute value of the vertex z position");
declareProperty( "TrackSelectionTool", m_trkSelTool, "Track selection tool" );
declareProperty( "MinNTrk", m_minNtrk, "Minimum number of associated tracks passing selection" );
declareProperty( "MinRmsPt", m_minRmsPt, "Minimum RMS pt [MeV] of associated tracks passing selection" );

Tracking Selection Tool (Working)

Track selection step InDetTrackSelectionTool.cxx. This one have many options to set, and many pre-define selection. By default is "NoCut"

Implementation
from InDetTrackSelectionTool.InDetTrackSelectionToolConf import InDet__InDetTrackSelectionTool
HITrackSelector=InDet__InDetTrackSelectionTool("InDetTrackSelectionTool_HILoose")
ToolSvc+=HITrackSelector
Options

declareProperty("CutLevel", m_cutLevel);

CutLevels

NoCut, Loose, LoosePrimary, TightPrimary, LooseMuon, LooseElectron, LooseTau, MinBias, HILoose, HITight.

Full Implementation

Keep in mind that the connections between the different tools is made with "declareProperty".

from DerivationFrameworkHI.DerivationFrameworkHIConf import DerivationFramework__HIMBSkimmingTool // HI MB Skimming set up
HIONSkimmingTool = DerivationFramework__HIMBSkimmingTool(name = "HIONSkimmingTool")
ToolSvc+=HIONSkimmingTool

from HIEventUtils.HIEventUtilsConf import HI__HIEventSelectionTool // HI Event Selection set up
HIEventSelector=HI__HIEventSelectionTool("HIEventSelector")
ToolSvc+=HIEventSelector

HIONSkimmingTool.HIEventSelectorTool=HIEventSelector // here we connect the Event selection to the Skimming tool

from HIEventUtils.HIEventUtilsConf import HI__HIVertexSelectionTool // Vertex Selection set up
HIVertexSelector=HI__HIVertexSelectionTool("HIVertexSelector")
ToolSvc+=HIVertexSelector

from InDetTrackSelectionTool.InDetTrackSelectionToolConf import InDet__InDetTrackSelectionTool // Tracking Selection set up
HITrackSelector=InDet__InDetTrackSelectionTool("InDetTrackSelectionTool_HILoose")
HITrackSelector.CutLevel = "HILoose" // Cut Level, NoCut by default 
ToolSvc+=HITrackSelector

HIVertexSelector.TrackSelectionTool=HITrackSelector // here we connect track selection with the vertex selection

HIEventSelector.VertexSelectionTool=HIVertexSelector // here we connect the vertex selection with Event selection

RootCore

HI Event Selection Tool (Working)

Last version of the HIEventSelectionTool is tagged in HIEventUtils-00-00-15, as the HIPileup rejection tool use ZDCModules and HIEventShape containers the ZDC calibration must be run first (at begging of your code!).

ZDC package is ubicated in:

atlasoff/ForwardDetectors/ZDC/ZdcAnalysis/trunk

Default mode of the tool required:

- Primary vertex

- Pileup rejection

Implementation

In you headers (.h) code:

#include "HIEventUtils/HIEventSelectionTool.h"
#include "ZdcAnalysis/ZdcAnalysisTool.h"

public:

HI::HIEventSelectionTool *m_hiEvtSelection; //!
ZDC::ZdcAnalysisTool *m_zdcTools; //!

In the Main(.cxx) code:

Initialization: initialize ()

// ZDCAnalysisTool
m_zdcTools = new ZDC::ZdcAnalysisTool("ZdcAnalysisTool");
ANA_CHECK(m_zdcTools->initializeTool());
// HIEventSlection
m_hiEvtSelection = new HI::HIEventSelectionTool("EventSelectionTool");
ANA_CHECK(m_hiEvtSelection->initialize() );

Execute: execute ()

// ZDC
m_zdcTools->reprocessZdc();
// check Good HI event
if( !m_hiEvtSelection->accept()) {
return EL::StatusCode::SUCCESS; // go to next event
}

If you want to remove the pileup rejection for crossChecks

ANA_CHECK(m_hiEvtSelection->setProperty("RejectPileup",false));

HI Pileup Tool (Working)

if you want to run only the pileup rejection:

Implementation

headers:

In you headers (.h) code:

#include "HIEventUtils/HIPileupTool.h"
#include "ZdcAnalysis/ZdcAnalysisTool.h"

public:

HI::HIPileupTool                      *m_hiPileup;    //!
ZDC::ZdcAnalysisTool *m_zdcTools; //!

In the Main(.cxx) code:

#include "xAODHIEvent/HIEventShapeContainer.h"
#include "xAODForward/ZdcModuleContainer.h"

Initialization: initialize ()

// ZDCAnalysisTool
m_zdcTools = new ZDC::ZdcAnalysisTool("ZdcAnalysisTool");
ANA_CHECK(m_zdcTools->initializeTool());
// HIPileupTool
m_hiPileup = new HI::HIPileupTool("PileupTool");
ANA_CHECK(m_hiPileup->initialize());

Execute: execute ()

const xAOD::ZdcModuleContainer* zdcMod = 0;
ANA_CHECK(event->retrieve( zdcMod, "ZdcModules")); 
const xAOD::HIEventShapeContainer* hiev = 0;
ANA_CHECK(event->retrieve( hiev, "HIEventShape"));
// ZDC
m_zdcTools->reprocessZdc();

// is Pileup
m_is_pileup = m_hiPileup->is_pileup( *hiev, *zdcMod); // SAVE pileup Decision HERE 0 = NO pileup, 1 = pileup

HI Vertex Selection Tool (Working)

Tracking Selection Tool (Working)

-- SebastianTapiaAraya - 2016-06-24

Edit | Attach | Watch | Print version | History: r10 < r9 < r8 < r7 < r6 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r10 - 2016-11-07 - SebastianTapiaAraya
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Main All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback