From 4a58c78bc1af68ef6c45d2022e7d4a48cb3838ff Mon Sep 17 00:00:00 2001
From: Frank Gaede <frank.gaede@desy.de>
Date: Fri, 7 Apr 2023 12:28:14 +0200
Subject: [PATCH] remove unit conversion in Geant4FastSimShowerModel

 - units from properties specified in ddsim_steer.py
   already are in G4units, so no conversion needed
---
 DDG4/src/Geant4FastSimShowerModel.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/DDG4/src/Geant4FastSimShowerModel.cpp b/DDG4/src/Geant4FastSimShowerModel.cpp
index ba78d89c4..69496dac3 100644
--- a/DDG4/src/Geant4FastSimShowerModel.cpp
+++ b/DDG4/src/Geant4FastSimShowerModel.cpp
@@ -186,7 +186,7 @@ void Geant4FastSimShowerModel::constructSensitives(Geant4DetectorConstructionCon
   G4Region* region = this->getRegion(this->m_regionName);
   for(const auto& prop : this->m_eTriggerNames)    {
     G4ParticleDefinition* def = this->getParticleDefinition(prop.first);
-    double val = dd4hep::_toDouble(prop.second)/dd4hep::GeV*CLHEP::GeV;
+    double val = dd4hep::_toDouble(prop.second) ; // allready in G4units /dd4hep::GeV*CLHEP::GeV;
     this->m_eTriggerCut.emplace(def, val);
     this->info("Set Energy(ModelTrigger) [%-16s] = %8.4f GeV", prop.first.c_str(), val);
   }
-- 
GitLab