diff --git a/Simulation/ISF/ISF_Core/FaserISF_Services/python/FaserISF_ServicesConfigNew.py b/Simulation/ISF/ISF_Core/FaserISF_Services/python/FaserISF_ServicesConfigNew.py index 4bf06b76f66ba0af57e64646cebc12b18b978612..41cdb42178c14f427d7c9bca447419b481160315 100644 --- a/Simulation/ISF/ISF_Core/FaserISF_Services/python/FaserISF_ServicesConfigNew.py +++ b/Simulation/ISF/ISF_Core/FaserISF_Services/python/FaserISF_ServicesConfigNew.py @@ -11,7 +11,7 @@ from AthenaConfiguration.ComponentFactory import CompFactory from BarcodeServices.BarcodeServicesConfigNew import MC15aPlusBarcodeSvcCfg from ISF_HepMC_Tools.ISF_HepMC_ToolsConfigNew import ParticleFinalStateFilterCfg, GenParticleInteractingFilterCfg # from FaserISF_HepMC_Tools.FaserISF_HepMC_ToolsConfigNew import FaserTruthStrategyCfg, FaserDipoleTruthStrategyCfg -from FaserISF_HepMC_Tools.FaserISF_HepMC_ToolsConfigNew import TruthStrategyGroupCfg +from FaserISF_HepMC_Tools.FaserISF_HepMC_ToolsConfigNew import TruthStrategyGroupCfg, TrenchStrategyGroupCfg ISF__FaserTruthSvc, ISF__FaserGeoIDSvc, ISF__FaserInputConverter = CompFactory.getComps("ISF::FaserTruthSvc","ISF::FaserGeoIDSvc","ISF::FaserInputConverter") @@ -66,7 +66,11 @@ def FaserTruthServiceCfg(ConfigFlags, name="FaserISF_TruthService", **kwargs): # kwargs.setdefault('TruthStrategies',[result.popToolsAndMerge(acc), result.popToolsAndMerge(acc2)]) acc = TruthStrategyGroupCfg(ConfigFlags) kwargs.setdefault('TruthStrategies', [result.popToolsAndMerge(acc)]) - + + # FaserNu hack + acc = TrenchStrategyGroupCfg(ConfigFlags) + kwargs.setdefault('TrenchStrategies', [result.popToolsAndMerge(acc)]) + kwargs.setdefault('SkipIfNoChildren', True) kwargs.setdefault('SkipIfNoParentBarcode', True) diff --git a/Simulation/ISF/ISF_HepMC/FaserISF_HepMC_Tools/python/FaserISF_HepMC_ToolsConfigNew.py b/Simulation/ISF/ISF_HepMC/FaserISF_HepMC_Tools/python/FaserISF_HepMC_ToolsConfigNew.py index 4f739f6c0ca89afab6020eab6f42e096e1f53545..1a08c8ba26d980d5e001fa27b1b2d1c6f7b616a4 100644 --- a/Simulation/ISF/ISF_HepMC/FaserISF_HepMC_Tools/python/FaserISF_HepMC_ToolsConfigNew.py +++ b/Simulation/ISF/ISF_HepMC/FaserISF_HepMC_Tools/python/FaserISF_HepMC_ToolsConfigNew.py @@ -173,6 +173,23 @@ def TruthStrategyGroupCfg(ConfigFlags, name="ISF_MCTruthStrategyGroupID", **kwar result.setPrivateTools(CompFactory.ISF.FaserTruthStrategy(name, **kwargs)) return result +# FaserNu hack +def TrenchStrategyGroupCfg(ConfigFlags, name="ISF_TrenchStrategyGroupID", **kwargs): + + import ROOT, cppyy + cppyy.load_library('FaserDetDescrDict') + FaserRegion = ROOT.FaserDetDescr.FaserRegion + + result = ComponentAccumulator() + kwargs.setdefault("ParentMinEkin", 10000.*MeV) + kwargs.setdefault("ChildMinEkin" , 10000.*MeV) + kwargs.setdefault("VertexTypes", [3, 14, 15, 4, 5, 6, 7, 2, 12, 13]) + kwargs.setdefault("VertexTypeRangeLow" , 201) # All kinds of decay processes + kwargs.setdefault("VertexTypeRangeHigh" , 298) # ... + kwargs.setdefault("Regions", [FaserRegion.fFaserTrench]) + result.setPrivateTools(CompFactory.ISF.FaserTruthStrategy(name, **kwargs)) + return result + # def FaserDipoleTruthStrategyCfg(ConfigFlags, name="ISF_FaserDipoleTruthStrategy", **kwargs): # result = ComponentAccumulator()