Skip to content
Snippets Groups Projects
Commit a47e0c4e authored by Elemer Nagy's avatar Elemer Nagy Committed by Graeme Stewart
Browse files

bugfix: test if input is simulation (TrigBjetMonitoring-00-03-10)

	* TrigBjetMonitoring-00-03-10
	* bugfix: test if input is simulation

2015-05-22 Elemer Nagy <Elemer.Nagy AT cern.ch>
	* TrigBjetMonitoring-00-03-09
	* temporary bugfix: no truthjet for real data
parent 1fdf980b
No related branches found
No related tags found
No related merge requests found
......@@ -32,6 +32,7 @@ use xAODBTagging xAODBTagging-* Event/xAOD
#use xAODCore xAODCore-* Event/xAOD
#use BTagging BTagging-* PhysicsAnalysis/JetTagging/JetTagAlgs
use xAODTracking xAODTracking-* Event/xAOD
use xAODEventInfo xAODEventInfo-* Event/xAOD
apply_tag ROOTGraphicsLibs
......
......@@ -55,6 +55,8 @@
#include "xAODTracking/TrackParticle.h"
#include "xAODEventInfo/EventInfo.h"
#include "EventPrimitives/EventPrimitivesHelpers.h"
......@@ -236,6 +238,13 @@ StatusCode HLTBjetMonTool::book(){
Fired:
const xAOD::EventInfo* eventInfo = 0;
// CHECK( evtStore()->retrieve( eventInfo) );
CHECK( evtStore()->retrieve( eventInfo, "EventInfo") );
bool MCflag = true;
if ( !eventInfo->eventType(xAOD::EventInfo::IS_SIMULATION) ) MCflag = false;
/////////////////////////////////////////
//
// Carlo's method, see /Trigger/TrigAnalysis/TrigBtagAnalysis/trunk/src/TrigBtagValidation.cxx
......@@ -247,9 +256,12 @@ StatusCode HLTBjetMonTool::book(){
ATH_MSG_INFO("PROCESSING TRIGITEM - " << trigItem);
// Get truth jets
const xAOD::JetContainer* truthjets = 0;
ATH_CHECK( evtStore()->retrieve(truthjets,"AntiKt4TruthJets") );
ATH_MSG_INFO("RETRIEVED TRUTH JETS - size: " << truthjets->size());
if (MCflag) {
const xAOD::JetContainer* truthjets = 0;
ATH_CHECK( evtStore()->retrieve(truthjets,"AntiKt4TruthJets") );
ATH_MSG_INFO("RETRIEVED TRUTH JETS - size: " << truthjets->size());
} // MCflag
// Get offline PV
const xAOD::VertexContainer* offlinepv = 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment