From 67d1d29fef2e1f19a201bd6bd192418ed5403a87 Mon Sep 17 00:00:00 2001 From: Markus Frank <Markus.Frank@cern.ch> Date: Mon, 29 Apr 2019 11:39:53 +0200 Subject: [PATCH] Add properties to Geant4GDMLWriteAction to steer writing of regions, cuts and sensitive detectors. See github issue https://github.com/AIDASoft/DD4hep/issues/507 --- DDG4/src/Geant4UIManager.cpp | 8 +------- examples/CLICSiD/scripts/CLIC_G4Gun.py | 6 ------ 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/DDG4/src/Geant4UIManager.cpp b/DDG4/src/Geant4UIManager.cpp index 3d6757a4d..37ebc5df8 100644 --- a/DDG4/src/Geant4UIManager.cpp +++ b/DDG4/src/Geant4UIManager.cpp @@ -152,14 +152,8 @@ void Geant4UIManager::start() { context()->kernel().runManager().BeamOn(numEvent); } catch (DD4hep_End_Of_File& e) { printout(INFO,"Geant4UIManager","++ End of file reached, ending run..."); + context()->kernel().runManager().RunTermination(); } - // Execute the chained command statements - for(const auto& c : m_postRunCommands) { - printout(INFO,"Geant4UIManager","++ Executing Command statement:%s",c.c_str()); - mgr->ApplyCommand(c.c_str()); - executed_statements = true; - } - context()->kernel().runManager().RunTermination(); } /// Stop and release resources diff --git a/examples/CLICSiD/scripts/CLIC_G4Gun.py b/examples/CLICSiD/scripts/CLIC_G4Gun.py index e0f49f1be..6964c4174 100644 --- a/examples/CLICSiD/scripts/CLIC_G4Gun.py +++ b/examples/CLICSiD/scripts/CLIC_G4Gun.py @@ -40,7 +40,6 @@ def run(): merger.enableUI() kernel.generatorAction().adopt(merger) - # And handle the simulation particles. part = DDG4.GeneratorAction(kernel,"Geant4ParticleHandler/ParticleHandler") kernel.generatorAction().adopt(part) @@ -52,11 +51,6 @@ def run(): user.enableUI() part.adopt(user) # - # Setup the GDML writer action - writer = DDG4.Action(kernel,'Geant4GDMLWriteAction/Writer') - writer.enableUI() - kernel.registerGlobalAction(writer) - sid.setupDetectors() sid.setupPhysics('QGSP_BERT') sid.test_config() -- GitLab