diff --git a/Generators/Pythia8_i/Pythia8_i/Pythia8_i.h b/Generators/Pythia8_i/Pythia8_i/Pythia8_i.h
index ef126b6bbb083d085e5e67a24574fe419de0313c..33f50aecaa0b2ad460fb25fe8d075ea2a6855b4c 100644
--- a/Generators/Pythia8_i/Pythia8_i/Pythia8_i.h
+++ b/Generators/Pythia8_i/Pythia8_i/Pythia8_i.h
@@ -1,5 +1,5 @@
 /*
-  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
+  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
   Author: James Monk
 */
 
@@ -16,7 +16,13 @@
 
 //#include "Pythia8/../Pythia8Plugins/HepMC2.h"
 #ifdef HEPMC3
-#include "Pythia8ToHepMC3.h"
+  #ifdef PYTHIA_VERSION_INTEGER 
+     #if PYTHIA_VERSION_INTEGER > 8299
+        #include "Pythia8Plugins/HepMC3.h"
+     #else
+        #include "Pythia8ToHepMC3.h"
+     #endif
+  #endif
 namespace HepMC {
 typedef HepMC3::Pythia8ToHepMC3 Pythia8ToHepMC;
 }
diff --git a/Generators/Pythia8_i/src/Pythia8_i.cxx b/Generators/Pythia8_i/src/Pythia8_i.cxx
index 462f69a2a8605d943de38e845c7562d0f419eeb5..b1422074f0da72bd844ef840c938e574af90e82f 100644
--- a/Generators/Pythia8_i/src/Pythia8_i.cxx
+++ b/Generators/Pythia8_i/src/Pythia8_i.cxx
@@ -115,7 +115,6 @@ m_athenaTool("")
   m_particleIDs["LEAD"]        = LEAD;
 
   ATH_MSG_INFO("XML Path is " + xmlpath());
-
   m_pythia = std::make_unique<Pythia8::Pythia> (xmlpath());
 #ifdef HEPMC3
   m_runinfo = std::make_shared<HepMC3::GenRunInfo>();
@@ -241,6 +240,8 @@ StatusCode Pythia8_i::genInitialize() {
     return StatusCode::FAILURE;
   }
 
+
+
   if(m_useRndmGenSvc){
 
     ATH_MSG_INFO(" !!!!!!!!!!!!  WARNING ON PYTHIA RANDOM NUMBERS !!!!!!!!!! ");
@@ -530,7 +531,6 @@ StatusCode Pythia8_i::fillEvt(HepMC::GenEvent *evt){
         }
         ++id;
       }
-
       std::map<std::string, Pythia8::LHAweight>::const_iterator weightName = m_pythia->info.init_weights->find(wgt->first);
       if(weightName != m_pythia->info.init_weights->end()){
         fWeights[weightName->second.contents] = mergingWeight * wgt->second.contents;
@@ -545,8 +545,7 @@ StatusCode Pythia8_i::fillEvt(HepMC::GenEvent *evt){
 
   for(int iw = firstWeight; iw < m_pythia->info.PYTHIA8_NWEIGHTS(); ++iw){
 
-    std::string wtName = ((int)m_showerWeightNames.size() == m_pythia->info.PYTHIA8_NWEIGHTS())? m_showerWeightNames[iw]: "ShowerWt_" +
-std::to_string(iw);
+    std::string wtName = ((int)m_showerWeightNames.size() == m_pythia->info.PYTHIA8_NWEIGHTS())? m_showerWeightNames[iw]: "ShowerWt_" +std::to_string(iw);
 
     if(m_pythia->info.PYTHIA8_NWEIGHTS() != 1){
       if(m_internal_event_number == 1) {
@@ -560,13 +559,15 @@ std::to_string(iw);
   }
 
 #ifdef HEPMC3
-  if(m_internal_event_number == 1){
-    std::vector<std::string> names;
-    for (auto w: fWeights)   names.push_back(w.first);
-    if (!evt->run_info()) evt->set_run_info(m_runinfo);
-    evt->run_info()->set_weight_names(names);
-  }
-  for (auto w: fWeights) {evt->weight(w.first)=w.second;}
+  std::vector<std::string> names;
+  for (auto w: fWeights)   names.push_back(w.first);
+  if (!evt->run_info()) evt->set_run_info(m_runinfo);
+  evt->run_info()->set_weight_names(names);
+// added conversion GeV ->  MeV to ensure correct units
+  GeVToMeV(evt);
+
+  for (auto w: fWeights) {
+      evt->weight(w.first)=w.second;}
 #else
   evt->weights().clear();
   for (auto w: fWeights) {evt->weights()[w.first]=w.second;}
@@ -580,7 +581,6 @@ std::to_string(iw);
 StatusCode Pythia8_i::genFinalize(){
 
   ATH_MSG_INFO(">>> Pythia8_i from genFinalize");
-
   m_pythia->stat();
 
   Pythia8::Info info = m_pythia->info;
@@ -636,7 +636,7 @@ StatusCode Pythia8_i::genFinalize(){
 void Pythia8_i::addLHEToHepMC(HepMC::GenEvent *evt){
 
 #ifdef HEPMC3
-  HepMC::GenEvent *procEvent = new HepMC::GenEvent(evt->momentum_unit(), evt->length_unit());
+  HepMC::GenEvent *procEvent = new HepMC::GenEvent();
 
   // Adding the LHE event to the HepMC results in undecayed partons in the event record.
   // Pythia's HepMC converter throws up undecayed partons, so we ignore that
@@ -654,6 +654,7 @@ void Pythia8_i::addLHEToHepMC(HepMC::GenEvent *evt){
   if(beams[0]->momentum().pz() * procBeams[0]->momentum().pz() < 0.) std::swap(procBeams[0],procBeams[1]);
   for (auto p: procBeams[0]->end_vertex()->particles_out())  beams[0]->end_vertex()->add_particle_out(p);
   for (auto p: procBeams[1]->end_vertex()->particles_out())  beams[1]->end_vertex()->add_particle_out(p);
+
 #else
   HepMC::GenEvent *procEvent = new HepMC::GenEvent(evt->momentum_unit(), evt->length_unit());
 
@@ -732,6 +733,7 @@ double Pythia8_i::pythiaVersion()const{
 ////////////////////////////////////////////////////////////////////////
 std::string Pythia8_i::xmlpath(){
 
+  
   std::string foundpath = "";
 
 // Try to find the xmldoc directory using PathResolver: