Skip to content
Snippets Groups Projects
Commit 74157dc8 authored by Frank Winklmeier's avatar Frank Winklmeier
Browse files

Merge branch 'hepmc3_PhysicsAnalysis_TruthParticleID_McParticleEvent_' into 'master'

Cleanup of McParticleEvent before migration to HepMC3

See merge request atlas/athena!34349
parents ed4f08c2 1fb552ff
No related branches found
No related tags found
No related merge requests found
/*
Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
*/
///////////////////////////////////////////////////////////////////
......
......@@ -106,12 +106,12 @@ class TruthParticleTest
public:
HepMC::GenEvent * m_evt;
HepMC::GenVertex * m_vtx;
HepMC::GenParticle * m_top;
HepMC::GenParticle * m_w;
HepMC::GenParticle * m_b;
HepMC::GenParticle * m_g1;
HepMC::GenParticle * m_g2;
HepMC::GenVertexPtr m_vtx;
HepMC::GenParticlePtr m_top;
HepMC::GenParticlePtr m_w;
HepMC::GenParticlePtr m_b;
HepMC::GenParticlePtr m_g1;
HepMC::GenParticlePtr m_g2;
unsigned int m_nPartsIn;
unsigned int m_nPartsOut;
......@@ -128,11 +128,11 @@ TruthParticleTest* makeTestData()
{
TruthParticleTest * test = new TruthParticleTest;
const int signalProcessId = 1000082;
const int evtNbr = 1;
HepMC::GenEvent * evt = new HepMC::GenEvent( signalProcessId, evtNbr );
HepMC::GenEvent * evt = new HepMC::GenEvent();
test->m_evt = evt;
evt->set_event_number(1);
evt->set_signal_process_id(1000082);
evt->set_event_scale( -1 );
evt->set_alphaQCD( -1 );
evt->set_alphaQED( -1 );
......@@ -148,12 +148,12 @@ TruthParticleTest* makeTestData()
evt->set_random_states( rdmStates );
// Add a t->W+bgg
HepMC::GenVertex * vtx = new HepMC::GenVertex;
HepMC::GenVertexPtr vtx = HepMC::newGenVertexPtr();
evt->add_vertex( vtx );
// top
HepMC::GenParticle * top = 0;
top = new HepMC::GenParticle( HLV_t(-2.35e+05,
HepMC::GenParticlePtr top =
HepMC::newGenParticlePtr( HLV_t(-2.35e+05,
+7.34e+04,
+3.60e+04,
+3.04e+05),
......@@ -162,32 +162,32 @@ TruthParticleTest* makeTestData()
// Wbgg
HepMC::GenParticle * w = 0;
w = new HepMC::GenParticle( HLV_t(-1.09e+05,
HepMC::GenParticlePtr w =
HepMC::newGenParticlePtr( HLV_t(-1.09e+05,
+6.99e+04,
-3.86e+04,
+1.57e+05),
24, 2 ) ;
vtx->add_particle_out(w);
HepMC::GenParticle * b = 0;
b = new HepMC::GenParticle( HLV_t(-9.23e+04,
HepMC::GenParticlePtr b =
HepMC::newGenParticlePtr( HLV_t(-9.23e+04,
+2.54e+03,
+5.32e+04,
+1.07e+05),
5, 2 );
vtx->add_particle_out(b);
HepMC::GenParticle * g1 = 0;
g1 = new HepMC::GenParticle( HLV_t(-4.76e+03,
HepMC::GenParticlePtr g1 =
HepMC::newGenParticlePtr( HLV_t(-4.76e+03,
+6.72e+02,
+2.90e+03,
+5.62e+03),
21, 2 );
vtx->add_particle_out( g1 );
HepMC::GenParticle * g2 = 0;
g2 = new HepMC::GenParticle( HLV_t(-2.93e+04,
HepMC::GenParticlePtr g2 =
HepMC::newGenParticlePtr( HLV_t(-2.93e+04,
+2.13e+02,
+1.85e+04,
+3.46e+04),
......@@ -445,13 +445,6 @@ void testSettersAndGetters( TruthParticleTest* tp )
++i ) {
etIsols.push_back( i*2.*CLHEP::GeV );
}
// TP_ASSERT( mc.etIsol() == tp->m_etIsols );
// mc.setEtIsol( etIsols );
// TP_ASSERT( mc.etIsol() == etIsols );
// mc.setEtIsol( TruthParticleParameters::etcone, -300.*CLHEP::GeV );
// TP_ASSERT( mc.etIsol(TruthParticleParameters::etcone) == -300.*CLHEP::GeV );
}
return;
......
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