Commit eb54e5c0 authored by Luisa Carvalho's avatar Luisa Carvalho Committed by Johannes Elmsheuser
Browse files

AFP+dijet chains based on simple hypo alg

parent 3ac47c59
# Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
class TestTrigAFPDijetHypoAlgConfig( TestTrigAFPDijetHypoAlg ):
__slots__ = []
def __init__(self, name = "TestTrigAFPDijetHypoAlgConfig"):
super( TestTrigAFPDijetHypoAlgConfig, self ).__init__( name )
monTool = GenericMonitoringTool("MonTool_"+name)
monTool.Histograms = [defineHistogram('DijetMass', type='TH1F', path='EXPERT', title="Dijet mass", xbins=100, xmin=0, xmax=200000)]
monTool.HistPath = 'AFPComboHypo/'+tool.getName()
afpProtonTransportToolSideA = AFPProtonTransportTool("AFPProtonTransportToolSideA_"+name)
afpProtonTransportToolSideC = AFPProtonTransportTool("AFPProtonTransportToolSideC_"+name)
self.protonTransportParamFileNameA="2017_beta0p4_xAngle170_beam1.txt"
self.protonTransportParamFileNameC="2017_beta0p4_xAngle170_beam2.txt"
self.alignmentCorrection_nearA=2.361
self.alignmentCorrection_nearC=2.172
self.MonTool = monTool
self.TransportBeamA = afpProtonTransportToolSideA
self.TransportBeamC = afpProtonTransportToolSideC
/*
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
*/
#include "TestTrigAFPDijetHypoAlg.h"
#include "xAODJet/Jet.h"
using TrigCompositeUtils::createAndStore;
using TrigCompositeUtils::DecisionContainer;
using TrigCompositeUtils::DecisionIDContainer;
using TrigCompositeUtils::decisionIDs;
using TrigCompositeUtils::hypoAlgNodeName;
using TrigCompositeUtils::linkToPrevious;
using TrigCompositeUtils::newDecisionIn;
using TrigCompositeUtils::featureString;
TestTrigAFPDijetHypoAlg::TestTrigAFPDijetHypoAlg(const std::string &name, ISvcLocator *pSvcLocator)
: ::HypoBase(name, pSvcLocator)
{
}
StatusCode TestTrigAFPDijetHypoAlg::initialize(){
ATH_MSG_DEBUG("In initialize ...");
ATH_CHECK(m_inputJetsKey.initialize());
ATH_CHECK(m_AFPtrackCollectionReadKey.initialize());
ATH_CHECK(m_hypoTools.retrieve());
return StatusCode::SUCCESS;
}
StatusCode TestTrigAFPDijetHypoAlg::execute(const EventContext &context) const {
ATH_MSG_DEBUG("Executing ...");
SG::ReadHandle<DecisionContainer> previousDecisionsHandle = SG::makeHandle(decisionInput(), context);
ATH_CHECK(previousDecisionsHandle.isValid());
auto inputJetsHandle = SG::makeHandle(m_inputJetsKey, context);
auto inputAFPtracksHandle = SG::makeHandle(m_AFPtrackCollectionReadKey, context);
ATH_MSG_DEBUG("Jet handle valid:"<<inputJetsHandle.isValid());
ATH_MSG_DEBUG("AFP handle valid:"<<inputAFPtracksHandle.isValid());
ATH_MSG_DEBUG("Jet collection size:"<<inputJetsHandle.cptr()->size());
ATH_MSG_DEBUG("AFP collection size:"<<inputAFPtracksHandle.cptr()->size());
TrigCompositeUtils::DecisionIDContainer prev;
TrigCompositeUtils::decisionIDs(previousDecisionsHandle->at(0), prev);
ATH_MSG_DEBUG("Created decisionIDs");
SG::WriteHandle<DecisionContainer> outputHandle = createAndStore(decisionOutput(), context);
auto decisions = outputHandle.ptr();
auto d = newDecisionIn(decisions, hypoAlgNodeName());
ATH_MSG_DEBUG("Created new decisionsIn");
linkToPrevious(d, decisionInput().key(), 0);
if(inputJetsHandle.cptr()->size()!=0) d->setObjectLink(featureString(), ElementLink<xAOD::JetContainer>(*inputJetsHandle, 0, context));
if(inputAFPtracksHandle.cptr()->size()!=0) d->setObjectLink(featureString(), ElementLink<xAOD::AFPTrackContainer>(*inputAFPtracksHandle, 0, context));
ATH_MSG_DEBUG("Linked to previous and to containers");
TestTrigAFPDijetHypoTool::TrigAFPDijetHypoInfo info = {prev,inputJetsHandle.cptr(),inputAFPtracksHandle.cptr(),d};
for (const auto &tool : m_hypoTools){
ATH_CHECK(tool->decide(info));
}
return StatusCode::SUCCESS;
}
/*
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
*/
#ifndef TRIGAFPHYPO_TESTTRIGAFPDIJETHYPOALG_H
#define TRIGAFPHYPO_TESTTRIGAFPDIJETHYPOALG_H
#include "DecisionHandling/HypoBase.h"
#include "Gaudi/Property.h"
#include "xAODJet/JetContainer.h"
#include "xAODJet/JetAuxContainer.h"
#include "xAODJet/Jet.h"
#include "xAODForward/AFPTrackContainer.h"
#include "xAODForward/AFPTrack.h"
#include "AthenaBaseComps/AthReentrantAlgorithm.h"
#include "StoreGate/ReadHandleKey.h"
#include "StoreGate/WriteHandleKey.h"
#include "TestTrigAFPDijetHypoTool.h"
class TestTrigAFPDijetHypoAlg : public ::HypoBase
{
public:
TestTrigAFPDijetHypoAlg(const std::string &name, ISvcLocator *pSvcLocator);
virtual StatusCode initialize() override;
virtual StatusCode execute(const EventContext &context) const override;
private:
ToolHandleArray<TestTrigAFPDijetHypoTool> m_hypoTools{this, "HypoTools", {}};
SG::ReadHandleKey< xAOD::JetContainer > m_inputJetsKey {this, "InputJetCollection", "HLT_xAOD__JetContainer_a4tcemsubjesISFS", "input jet container key"};
SG::ReadHandleKey< xAOD::AFPTrackContainer > m_AFPtrackCollectionReadKey {this, "AFPTrackContainer", "HLT_AFPTrackContainer", "xAOD AFP track collection"};
};
#endif // TRIGAFPHYPO_TESTTRIGAFPDIJETHYPOALG_H
/*
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
*/
#include "TrigCompositeUtils/TrigCompositeUtils.h"
#include "TestTrigAFPDijetHypoTool.h"
#include "PathResolver/PathResolver.h"
using TrigCompositeUtils::addDecisionID;
TestTrigAFPDijetHypoTool::TestTrigAFPDijetHypoTool(const std::string &type, const std::string &name, const IInterface *parent)
: AthAlgTool(type, name, parent),
m_decisionId(HLT::Identifier::fromToolName(name)),
m_transportBeamA("AFPProtonTransportTool/TransportBeamA", this),
m_transportBeamC("AFPProtonTransportTool/TransportBeamC", this)
{
declareProperty("TransportBeamA",m_transportBeamA,"Proton transport tool side A");
declareProperty("TransportBeamC",m_transportBeamC,"Proton transport tool side C");
}
StatusCode TestTrigAFPDijetHypoTool::initialize()
{
if (!(m_monTool.name().empty())) {
ATH_CHECK( m_monTool.retrieve() );
ATH_MSG_DEBUG("m_monTool name: " << m_monTool);
}
if(!(m_transportBeamA.name().empty())){
ATH_CHECK( m_transportBeamA.retrieve() );
ATH_MSG_DEBUG("m_transportBeamA name: " << m_transportBeamA);
}
if(!(m_transportBeamC.name().empty())){
ATH_CHECK( m_transportBeamC.retrieve() );
ATH_MSG_DEBUG("m_transportBeamC name: " << m_transportBeamC);
}
//Retrieving the parameterization file for A side
// By default it used file final_parameterization_b1.txt
ATH_MSG_DEBUG("Parameterization file for A side: "<< m_protonTransportParamFileNameA);
std::string filePathA = PathResolver::find_file(m_protonTransportParamFileNameA, "DATAPATH", PathResolver::RecursiveSearch);
ATH_MSG_DEBUG("Path to param file side A: "<<filePathA);
//Defining the parameterization object
m_transportBeamA->setParamFile(filePathA);
ATH_CHECK(m_transportBeamA->load());
//Retrieving the parameterization file for C side
// By default it used file final_parameterization_b2.txt
ATH_MSG_DEBUG("Parameterization file for C side: "<< m_protonTransportParamFileNameC);
std::string filePathC = PathResolver::find_file(m_protonTransportParamFileNameC, "DATAPATH", PathResolver::RecursiveSearch);
ATH_MSG_DEBUG("Path to param file side C: "<<filePathC);
//Defining the parameterization object
m_transportBeamC->setParamFile(filePathC);
ATH_CHECK(m_transportBeamC->load());
return StatusCode::SUCCESS;
}
StatusCode TestTrigAFPDijetHypoTool::decide(TrigAFPDijetHypoInfo &info) const {
// Get input jet collection
const xAOD::JetContainer *jetCollection = info.jetInputCollection;
if(jetCollection->size()<2){
ATH_MSG_DEBUG("Number of jets is smaller than 2");
return StatusCode::SUCCESS;
}
// Get two leading jets
const xAOD::Jet *jet1 = jetCollection->at(0);
const xAOD::Jet *jet2 = jetCollection->at(1);
ATH_MSG_DEBUG("Jets pt:"<<jet1->pt()<<";"<<jet2->pt());
TLorentzVector dijet = jet1->p4() + jet2->p4();
// Calculate dijet quantities
auto dijetMass = Monitored::Scalar( "DijetMass" , -1.0 );
//auto monitorIt = Monitored::Group( m_monTool, dijetMass);
auto dijetRapidity = Monitored::Scalar( "DijetRapidity" , -1.0 );
dijetMass = dijet.M() * m_GeV;
dijetRapidity = dijet.Rapidity();
Monitored::fill(m_monTool, dijetMass);
Monitored::fill(m_monTool, dijetRapidity);
// Calculate relative energy loss
auto xiJet1 = Monitored::Scalar( "XiJet1" , -1.0 );
auto xiJet2 = Monitored::Scalar( "XiJet2" , -1.0 );
xiJet1 = exp(dijetRapidity) * dijetMass / m_totalEnergy;
xiJet2 = exp(-dijetRapidity) * dijetMass / m_totalEnergy;
ATH_MSG_DEBUG("xi Jet 2:"<<xiJet2);
Monitored::fill(m_monTool, xiJet1);
Monitored::fill(m_monTool, xiJet2);
// Predict proton positions on AFP sides A and C
auto predictProtonAEnergy = Monitored::Scalar( "PredictProtonAEnergy" , -1.0 );
auto predictProtonCEnergy = Monitored::Scalar( "PredictProtonCEnergy" , -1.0 );
predictProtonAEnergy = m_beamEnergy * (1. - xiJet1); // Side A
predictProtonCEnergy = m_beamEnergy * (1. - xiJet2); // Side C
ATH_MSG_DEBUG("Predict proton energy A:"<<predictProtonAEnergy);
ATH_MSG_DEBUG("Predict proton energy C:"<<predictProtonCEnergy);
Monitored::fill(m_monTool, predictProtonAEnergy);
Monitored::fill(m_monTool, predictProtonCEnergy);
// Side A position prediction
auto sideA_predictX = Monitored::Scalar( "SideA_predictX" , -1.0 );
auto sideA_predictY = Monitored::Scalar( "SideA_predictY" , -1.0 );
sideA_predictX = 1e3 * m_transportBeamA->x(0, 0, 0, 0, 0, predictProtonAEnergy) + m_protonPosShift_x;
sideA_predictY = 1e3 * m_transportBeamA->x(0, 0, 0, 0, 0, predictProtonAEnergy) + m_protonPosShift_y;
ATH_MSG_DEBUG("Side A predict X:"<<sideA_predictX);
Monitored::fill(m_monTool, sideA_predictX);
Monitored::fill(m_monTool, sideA_predictY);
// Side C position prediction
auto sideC_predictX = Monitored::Scalar( "SideC_predictX" , -1.0 );
auto sideC_predictY = Monitored::Scalar( "SideC_predictY" , -1.0 );
sideC_predictX = 1e3 * m_transportBeamC->x(0, 0, 0, 0, 0, predictProtonCEnergy) + m_protonPosShift_x;
sideC_predictY = 1e3 * m_transportBeamC->x(0, 0, 0, 0, 0, predictProtonCEnergy) + m_protonPosShift_y;
ATH_MSG_DEBUG("Side C predict X:"<<sideA_predictX);
Monitored::fill(m_monTool, sideC_predictX);
Monitored::fill(m_monTool, sideC_predictY);
// Get input track collection
const xAOD::AFPTrackContainer *afpTrackCollection = info.afpTracksInputCollection;
if(afpTrackCollection==nullptr){
ATH_MSG_DEBUG("AFP track collection is null");
return StatusCode::SUCCESS;
}
if(afpTrackCollection->size()<2){
ATH_MSG_DEBUG("Less than 2 track reconstructed in AFP");
return StatusCode::SUCCESS;
}
double sideA_minDist = 9e9;
double sideC_minDist = 9e9;
int nearestTrackSideAId = 999;
int nearestTrackSideCId = 999;
auto xDiff = Monitored::Scalar("XDiff",-1.0);
auto yDiff = Monitored::Scalar("YDiff",-1.0);
auto distance = Monitored::Scalar("distance",-1.0);
for(auto track: (*afpTrackCollection)){
xDiff = -1.0;
yDiff = -1.0;
distance = -1.0;
if(track->stationID() == 1){
xDiff = sideA_predictX - (track->xLocal() + m_alignmentCorrection_nearA);
yDiff = sideA_predictY - track->yLocal();
distance = sqrt(xDiff * xDiff + yDiff * yDiff);
if(distance < sideA_minDist){
sideA_minDist = distance;
nearestTrackSideAId = track->index();
}
}else if(track->stationID() == 2){
xDiff = sideC_predictX - (track->xLocal() + m_alignmentCorrection_nearC);
yDiff = sideC_predictY - track->yLocal();
distance = sqrt(xDiff * xDiff + yDiff * yDiff);
if(distance < sideC_minDist){
sideC_minDist = distance;
nearestTrackSideCId = track->index();
}
}// End of if for choosing AFP station
ATH_MSG_DEBUG("X diff:"<<xDiff);
ATH_MSG_DEBUG("Y diff:"<<yDiff);
Monitored::fill(m_monTool, xDiff);
Monitored::fill(m_monTool, yDiff);
Monitored::fill(m_monTool, distance);
}// End of loop over AFP tracks
bool passRCutA = false;
bool passRCutC = false;
bool passXYCutA = false;
bool passXYCutC = false;
auto sideA_trackX = Monitored::Scalar("SideA_trackX",-1.0);
auto sideA_trackY = Monitored::Scalar("SideA_trackY",-1.0);
auto sideA_diffX = Monitored::Scalar("SideA_diffX",-1.0);
auto sideA_diffY = Monitored::Scalar("SideA_diffY",-1.0);
auto sideC_trackX = Monitored::Scalar("SideC_trackX",-1.0);
auto sideC_trackY = Monitored::Scalar("SideC_trackY",-1.0);
auto sideC_diffX = Monitored::Scalar("SideC_diffX",-1.0);
auto sideC_diffY = Monitored::Scalar("SideC_diffY",-1.0);
// Cuts on A side
if(nearestTrackSideAId != 999){
sideA_trackX = afpTrackCollection->at(nearestTrackSideAId)->xLocal() + m_alignmentCorrection_nearA;
sideA_trackY = afpTrackCollection->at(nearestTrackSideAId)->yLocal();
sideA_diffX = sideA_predictX - sideA_trackX;
sideA_diffY = sideA_predictY - sideA_trackY;
if(sideA_minDist < m_maxProtonDist) passRCutA = true;
if(std::abs(sideA_diffX) < m_maxProtonDiff_x && std::abs(sideA_diffY) < m_maxProtonDiff_y) passXYCutA = true;
}else{
passRCutA = false;
passXYCutA = false;
}
// Cuts on C side
if(nearestTrackSideCId != 999){
sideC_trackX = afpTrackCollection->at(nearestTrackSideCId)->xLocal() + m_alignmentCorrection_nearC;
sideC_trackY = afpTrackCollection->at(nearestTrackSideCId)->yLocal();
sideC_diffX = sideC_predictX - sideC_trackX;
sideC_diffY = sideC_predictY - sideC_trackY;
if(sideC_minDist < m_maxProtonDist) passRCutC = true;
if(std::abs(sideC_diffX) < m_maxProtonDiff_x && std::abs(sideC_diffY) < m_maxProtonDiff_y) passXYCutC = true;
}else{
passRCutC = false;
passXYCutC = false;
}
Monitored::fill(m_monTool,sideA_trackX);
Monitored::fill(m_monTool,sideA_trackY);
Monitored::fill(m_monTool,sideA_diffX);
Monitored::fill(m_monTool,sideA_diffY);
Monitored::fill(m_monTool,sideC_trackX);
Monitored::fill(m_monTool,sideC_trackY);
Monitored::fill(m_monTool,sideC_diffX);
Monitored::fill(m_monTool,sideC_diffY);
bool pass = false;
if(passRCutA && passRCutC && passXYCutA && passXYCutC) pass = true;
if(pass){
addDecisionID(m_decisionId.numeric(), info.decision);
ATH_MSG_DEBUG("Event accepted");
}else{
ATH_MSG_DEBUG("Event rejected");
}
return StatusCode::SUCCESS;
}
/*
Copyright! (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
*/
#ifndef TRIGAFPHYPO_TestTrigAFPDijetHypoTool_H
#define TRIGAFPHYPO_TestTrigAFPDijetHypoTool_H
#include "Gaudi/Property.h"
#include "AthenaBaseComps/AthAlgTool.h"
#include "TrigCompositeUtils/HLTIdentifier.h"
#include "xAODJet/JetContainer.h"
#include "xAODJet/JetAuxContainer.h"
#include "xAODJet/Jet.h"
#include "xAODForward/AFPTrackContainer.h"
#include "xAODForward/AFPTrack.h"
#include "AthenaMonitoringKernel/Monitored.h"
#include "AthenaMonitoringKernel/GenericMonitoringTool.h"
#include "IAFPProtonTransportTool.h"
#include "AFPProtonTransportTool.h"
class TestTrigAFPDijetHypoTool : virtual public ::AthAlgTool
{
public:
TestTrigAFPDijetHypoTool(const std::string &type,
const std::string &name,
const IInterface *parent);
virtual StatusCode initialize() override;
struct TrigAFPDijetHypoInfo
{
const TrigCompositeUtils::DecisionIDContainer previousDecisionIDs;
const xAOD::JetContainer *jetInputCollection;
const xAOD::AFPTrackContainer *afpTracksInputCollection;
TrigCompositeUtils::Decision *decision;
};
StatusCode decide(TrigAFPDijetHypoInfo &decisions) const;
private:
HLT::Identifier m_decisionId;
//Proton transport parameterizaton file for A side
Gaudi::Property<std::string> m_protonTransportParamFileNameA{this,"protonTransportParamFileName1","final_parameterization_b1.txt","Name of the file with proton transport parameterization for A side"};
//Proton transport parameterizaton file for C side
Gaudi::Property<std::string> m_protonTransportParamFileNameC{this,"protonTransportParamFileName2","final_parameterization_b2.txt","Name of the file with proton transport parameterization C side"};
//Proton transport parameterizaton object used in the proton position prediction for ATLAS A side
ToolHandle<IAFPProtonTransportTool> m_transportBeamA;
///Proton transport parameterizaton object used in the proton position prediction for ATLAS C side
ToolHandle<IAFPProtonTransportTool> m_transportBeamC;
///Threshold for the radius distance between parameterization and measurements (in mm)
Gaudi::Property<float> m_maxProtonDist{this,"maxProtonDist",2.0,"Cut on distance between measured and extrapolated proton"};
///Threshold for the x distance between parameterization and measurements (in mm)
Gaudi::Property<float> m_maxProtonDiff_x{this,"maxProtonDiff_x",2.5,"Cut on x difference between measured and extrapolated proton"};
///Threshold for the y distance between parameterization and measurements (in mm)
Gaudi::Property<float> m_maxProtonDiff_y{this,"maxProtonDiff_y",2.5,"Cut on y difference between measured and extrapolated proton"};
Gaudi::Property<float> m_beamEnergy{this,"beamEnergy",6500.0,"Energy of one beam i.e. half of centre-of-mass energy"}; ///< energy of one beam i.e. half of centre-of-mass energy
float m_totalEnergy = 2*m_beamEnergy; ///< beams centre-of-mass energy 2*#m_beamEnergy
///Shift in x position between parameterization and measurements (in mm)
Gaudi::Property<float> m_protonPosShift_x{this,"protonPosShift_x",-97.0,"Expected difference in x position between measured and predicted proton"};
///Shif in y position between parameterization and measurements (in mm)
Gaudi::Property<float> m_protonPosShift_y{this,"protonPosShift_y",5.0,"Expected difference in y position between measured and predicted proton"};
///Beam alignment corrections in the x position of ATLAS A side (in mm)
Gaudi::Property<float> m_alignmentCorrection_nearA{this,"alignmentCorrection_nearA",0.0,"Shift due to alignment in x for protons in near station A"};
///Beam alignment corrections in the x position of ATLAS C side (in mm)
Gaudi::Property<float> m_alignmentCorrection_nearC{this,"alignmentCorrection_nearC",0.0,"Shift due to alignment in x for protons in near station C"};
///Variable to convert from MeV to GeV
const float m_GeV = 0.001;
// monitoring
ToolHandle<GenericMonitoringTool> m_monTool { this, "MonTool", "", "Monitoring tool" };
};
#endif // TRIGAFPHYPO_TestTrigAFPDijetHypoTool_H
#include "../TrigAFPDijetComboHypoTool.h"
#include "../AFPProtonTransportTool.h"
#include "../TestTrigAFPDijetHypoAlg.h"
#include "../TestTrigAFPDijetHypoTool.h"
DECLARE_COMPONENT( TestTrigAFPDijetHypoAlg )
DECLARE_COMPONENT( TestTrigAFPDijetHypoTool )
DECLARE_COMPONENT( TrigAFPDijetComboHypoTool )
DECLARE_COMPONENT( AFPProtonTransportTool )
......@@ -5698,6 +5698,12 @@ HLT_larpsallem_L1EM3:
0: 20
stepFeatures:
0: 166
HLT_mb_afphypo_j0_L1RD0_FILLED:
eventCount: 0
stepCounts:
0: 20
stepFeatures:
0: 387
HLT_mb_afprec_L1AFP_A_AND_C_TOF_J20:
eventCount: 0
HLT_mb_afprec_L1AFP_A_AND_C_TOF_J30:
......
......@@ -2234,6 +2234,12 @@ HLT_larpsallem_L1EM3:
0: 13
stepFeatures:
0: 42
HLT_mb_afphypo_j0_L1RD0_FILLED:
eventCount: 0
stepCounts:
0: 20
stepFeatures:
0: 183
HLT_mb_afprec_L1AFP_A_AND_C_TOF_J20:
eventCount: 0
HLT_mb_afprec_L1AFP_A_AND_C_TOF_J30:
......
......@@ -925,6 +925,7 @@ def setupMenu():
ChainProp(name='HLT_j55_0eta240_xe50_cell_L1J30_FIRSTEMPTY', l1SeedThresholds=['FSNOSEED']*2, stream=['Late'], groups=PrimaryLegGroup+JetMETGroup),
# high-mu AFP
ChainProp(name='HLT_mb_afphypo_j0_L1RD0_FILLED', l1SeedThresholds=['FSNOSEED']*2, stream=[PhysicsStream], groups=MinBiasGroup+LowMuGroup+SupportLegGroup),
#ChainProp(name='HLT_mb_afprec_2j20_afpdijet_L1RD0_FILLED', l1SeedThresholds=['FSNOSEED']*2, stream=[PhysicsStream],groups=MinBiasGroup+LowMuGroup+SupportLegGroup),
# bjet+met+met
......@@ -1008,7 +1009,6 @@ def setupMenu():
ChainProp(name='HLT_mb_afprec_L1AFP_A_AND_C_TOF_T0T1_J50', l1SeedThresholds=['FSNOSEED'], stream=[PhysicsStream], groups=['PS:Online']+MinBiasGroup+LowMuGroup),
ChainProp(name='HLT_mb_afprec_L1AFP_A_AND_C_TOF_J75', l1SeedThresholds=['FSNOSEED'], stream=[PhysicsStream], groups=['PS:Online']+MinBiasGroup+LowMuGroup),
ChainProp(name='HLT_mb_afprec_L1AFP_A_AND_C_TOF_T0T1_J75', l1SeedThresholds=['FSNOSEED'], stream=[PhysicsStream], groups=['PS:Online']+MinBiasGroup+LowMuGroup),
ChainProp(name='HLT_mb_sptrk_vetombts2in_L1RD0_FILLED', l1SeedThresholds=['FSNOSEED'], stream=[PhysicsStream], groups=['PS:Online']+MinBiasGroup+LowMuGroup),
]
......
......@@ -630,7 +630,7 @@ MinBiasChainParts = {
'trk100', 'trk110', 'trk120', 'trk130', 'trk140', 'trk150', 'trk160', 'trk180', 'trk200', 'trk220', 'trk240', 'trk260', 'trk280',
'pt2', 'pt4', 'pt6', 'pt8', ],
'hypoEFsumEtInfo': ['sumet40', 'sumet50', 'sumet60', 'sumet70', 'sumet80', 'sumet90', 'sumet110', 'sumet150',],
'recoAlg' : ['mbts', 'sptrk', 'sp', 'noalg', 'perf', 'hmt', 'hmtperf', 'idperf', 'zdcperf', 'alfaperf','afprec'],
'recoAlg' : ['mbts', 'sptrk', 'sp', 'noalg', 'perf', 'hmt', 'hmtperf', 'idperf', 'zdcperf', 'alfaperf','afprec','afphypo'],
'addInfo' : ['peb'],
'sigFolder' : 'MinBias',
'subSigs' : ['MinBias'],
......
......@@ -2,14 +2,16 @@
# Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
#
from AthenaConfiguration.AllConfigFlags import ConfigFlags
from TriggerMenuMT.HLTMenuConfig.Menu.MenuComponents import MenuSequence
from AthenaCommon.CFElements import parOR, seqAND
from AthenaConfiguration.ComponentAccumulator import conf2toConfigurable
from DecisionHandling.DecisionHandlingConf import InputMakerForRoI, ViewCreatorInitialROITool
from AthenaCommon.GlobalFlags import globalflags
from TrigEDMConfig.TriggerEDMRun3 import recordable
from TriggerMenuMT.HLTMenuConfig.Menu.MenuComponents import RecoFragmentsPool
def AFPTrkRecoSequence():
def AFPTrkRecoBaseSequence(ConfigFlags):
# Create inputs using input maker
AFPInputMaker = InputMakerForRoI("IM_AFPTrackingFS")
......@@ -76,6 +78,18 @@ def AFPTrkRecoSequence():
# AFP_TDLocReco.ListAlgoTD = ["TDZVertex"]
# AFP_TDLocReco.AmpThresh = 10.
AFPRecoSeq = parOR("AFPRecoSeq", [AFP_Raw, AFP_R2D, AFP_SID])
return (AFPRecoSeq, AFPInputMaker)
def AFPTrkRecoSequence():
# Retrieve input maker and reco seq
(AFPPassThroughRecoSeq, AFPPassThroughInputMaker) = RecoFragmentsPool.retrieve(AFPTrkRecoBaseSequence,ConfigFlags)
AFPPassThroughSequence = seqAND("AFPPassThroughSequence", [AFPPassThroughInputMaker, AFPPassThroughRecoSeq])
from AthenaConfiguration.ComponentFactory import CompFactory
# Pass-through hypo
def trigStreamerAFPHypoTool(chain_dict):
return conf2toConfigurable(CompFactory.TrigStreamerHypoTool(chain_dict["chainName"]))
......@@ -83,11 +97,63 @@ def AFPTrkRecoSequence():
hypo = conf2toConfigurable(CompFactory.TrigStreamerHypoAlg("AFPPassThroughHypo"))