Skip to content
Snippets Groups Projects
Commit f4a63ded authored by Elmar Ritsch's avatar Elmar Ritsch Committed by Graeme Stewart
Browse files

Move file skip_if_AthSimulation.sh from ISF_Validation into this package...

Move file skip_if_AthSimulation.sh from ISF_Validation into this package (SimuJobTransforms-00-33-01)

	* scripts/skip_if_AthSimulation.sh: File moved from ISF_Validation package
	into this package. ATLASSIM-3149
	* CMakeLists.txt, cmt/requirements: Update both to pick up and install
	skip_if_AthSimulation.sh script.
	* Tagging: SimuJobTransforms-00-33-01

2016-11-11  John Chapman  <John.Chapman@cern.ch>

	* share/skeleton.FilterHit.py: Update to use
	AddressRemappingSvc (if available) to alias input SimHit
	collection names. ATLASSIM-2000. Avoid trying to write out both
	MBTS and HGTD SimHit collections.
	* python/HitsFilePeeker.py (hitColls2SimulatedDetectors): check
	for HGTD hit container.
	* Tagging: SimuJobTransforms-00-33-00

2016-10-17  John Chapman  <John.Chapman@cern.ch>

	* share/skeleton.EVGENtoHIT_ISF.py,
...
(Long ChangeLog diff - truncated)


Former-commit-id: 1352833c9a56b2d7dd598efee15d453752f67db5
parent 1afe2b28
No related branches found
No related tags found
No related merge requests found
...@@ -16,5 +16,6 @@ find_package( PythonLibs ) ...@@ -16,5 +16,6 @@ find_package( PythonLibs )
atlas_install_python_modules( python/*.py ) atlas_install_python_modules( python/*.py )
atlas_install_joboptions( share/*.py ) atlas_install_joboptions( share/*.py )
atlas_install_runtime( scripts/*.py ) atlas_install_runtime( scripts/*.py )
atlas_install_runtime( scripts/*.sh )
atlas_install_runtime( test/SimuJobTransforms_TestConfiguration.xml ) atlas_install_runtime( test/SimuJobTransforms_TestConfiguration.xml )
...@@ -6,5 +6,6 @@ use PyJobTransforms PyJobTransforms-* Tools ...@@ -6,5 +6,6 @@ use PyJobTransforms PyJobTransforms-* Tools
apply_pattern declare_python_modules files="*.py" apply_pattern declare_python_modules files="*.py"
apply_pattern declare_job_transforms tfs='*.py' jo='*.py' apply_pattern declare_job_transforms tfs='*.py' jo='*.py'
apply_pattern declare_scripts files="../scripts/*.sh"
macro SimuJobTransforms_TestConfiguration "../test/SimuJobTransforms_TestConfiguration.xml" macro SimuJobTransforms_TestConfiguration "../test/SimuJobTransforms_TestConfiguration.xml"
apply_pattern declare_runtime_extras extras="../test/SimuJobTransforms_TestConfiguration.xml" apply_pattern declare_runtime_extras extras="../test/SimuJobTransforms_TestConfiguration.xml"
...@@ -5,7 +5,7 @@ def hitColls2SimulatedDetectors(inputlist): ...@@ -5,7 +5,7 @@ def hitColls2SimulatedDetectors(inputlist):
simulatedDetectors = [] simulatedDetectors = []
simulatedDictionary = {'PixelHits': 'pixel', 'SCT_Hits': 'SCT', 'TRTUncompressedHits': 'TRT', simulatedDictionary = {'PixelHits': 'pixel', 'SCT_Hits': 'SCT', 'TRTUncompressedHits': 'TRT',
'BCMHits': 'BCM', 'LucidSimHitsVector': 'Lucid', 'LArHitEMB': 'LAr', 'BCMHits': 'BCM', 'LucidSimHitsVector': 'Lucid', 'LArHitEMB': 'LAr',
'LArHitEMEC': 'LAr', 'LArHitFCAL': 'LAr', 'LArHitHEC': 'LAr', 'LArHitEMEC': 'LAr', 'LArHitFCAL': 'LAr', 'LArHitHEC': 'LAr', 'LArHitHGTD': 'HGTD',
'MBTSHits': 'Tile', 'TileHitVec': 'Tile', 'MDT_Hits': 'MDT', 'MBTSHits': 'Tile', 'TileHitVec': 'Tile', 'MDT_Hits': 'MDT',
'MicromegasSensitiveDetector': 'Micromegas', 'MicromegasSensitiveDetector': 'Micromegas',
'sTGCSensitiveDetector': 'sTGC', 'sTGCSensitiveDetector': 'sTGC',
......
#!/bin/bash
SCRIPTNAME=$(basename $0)
echo "$SCRIPTNAME: command provided: \"$@\""
if [[ "$ATLAS_RELEASE_BASE" != *"AthSimulation"* ]]; then
echo "$SCRIPTNAME: will execute provided command as this is not an AthSimulation environment"
$@
# take return value from executed command
exit $?
else
echo "$SCRIPTNAME: this is an AthSimulation build environment, *not* executing provided command"
fi
...@@ -317,14 +317,12 @@ if hasattr(runArgs, "postExec"): ...@@ -317,14 +317,12 @@ if hasattr(runArgs, "postExec"):
## Always enable the looper killer, unless it's been disabled ## Always enable the looper killer, unless it's been disabled
if not hasattr(runArgs, "enableLooperKiller") or runArgs.enableLooperKiller: if not hasattr(runArgs, "enableLooperKiller") or runArgs.enableLooperKiller:
if ISF_Flags.UsingGeant4(): if ISF_Flags.UsingGeant4():
if (hasattr(simFlags, 'UseV2UserActions') and simFlags.UseV2UserActions()): # this configures the MT LooperKiller
# this configures the MT LooperKiller try:
from G4UserActions import G4UserActionsConfig from G4UserActions import G4UserActionsConfig
try: G4UserActionsConfig.addLooperKillerTool()
G4UserActionsConfig.addLooperKillerTool() except AttributeError, ImportError:
except AttributeError: atlasG4log.warning("Could not add the MT-version of the LooperKiller")
atlasG4log.warning("Could not add the MT-version of the LooperKiller")
else:
# this configures the non-MT looperKiller # this configures the non-MT looperKiller
try: try:
from G4AtlasServices.G4AtlasUserActionConfig import UAStore from G4AtlasServices.G4AtlasUserActionConfig import UAStore
......
...@@ -287,14 +287,12 @@ if hasattr(runArgs, "postExec"): ...@@ -287,14 +287,12 @@ if hasattr(runArgs, "postExec"):
## Always enable the looper killer, unless it's been disabled ## Always enable the looper killer, unless it's been disabled
if not hasattr(runArgs, "enableLooperKiller") or runArgs.enableLooperKiller: if not hasattr(runArgs, "enableLooperKiller") or runArgs.enableLooperKiller:
if (hasattr(simFlags, 'UseV2UserActions') and simFlags.UseV2UserActions()): # this configures the MT LooperKiller
# this configures the MT LooperKiller try:
from G4UserActions import G4UserActionsConfig from G4UserActions import G4UserActionsConfig
try: G4UserActionsConfig.addLooperKillerTool()
G4UserActionsConfig.addLooperKillerTool() except AttributeError, ImportError:
except AttributeError: atlasG4log.warning("Could not add the MT-version of the LooperKiller")
atlasG4log.warning("Could not add the MT-version of the LooperKiller")
else:
# this configures the non-MT looperKiller # this configures the non-MT looperKiller
try: try:
from G4AtlasServices.G4AtlasUserActionConfig import UAStore from G4AtlasServices.G4AtlasUserActionConfig import UAStore
......
...@@ -152,10 +152,17 @@ Stream1.ItemList += ["SiHitCollection#SCT_Hits"] ...@@ -152,10 +152,17 @@ Stream1.ItemList += ["SiHitCollection#SCT_Hits"]
#TRT #TRT
Stream1.ItemList += ["TRTUncompressedHitCollection#TRTUncompressedHits"] Stream1.ItemList += ["TRTUncompressedHitCollection#TRTUncompressedHits"]
#LAr #LAr
Stream1.ItemList += ["LArHitContainer#*"] Stream1.ItemList += ["LArHitContainer#LArHitEMB"]
Stream1.ItemList += ["LArHitContainer#LArHitEMEC"]
Stream1.ItemList += ["LArHitContainer#LArHitHEC"]
Stream1.ItemList += ["LArHitContainer#LArHitFCAL"]
#Tile #Tile
Stream1.ItemList += ["TileHitVector#TileHitVec", Stream1.ItemList += ["TileHitVector#TileHitVec"]
"TileHitVector#MBTSHits"]
if hasattr(DetFlags.detdescr, 'HGTD_on') and DetFlags.detdescr.HGTD_on():
Stream1.ItemList += ["LArHitContainer#LArHitHGTD"]
else:
Stream1.ItemList += ["TileHitVector#MBTSHits"]
#Calo Calibration Hits - not required, so leave out to save space #Calo Calibration Hits - not required, so leave out to save space
#Stream1.ItemList += ["CaloCalibrationHitContainer#LArCalibrationHitActive", #Stream1.ItemList += ["CaloCalibrationHitContainer#LArCalibrationHitActive",
# "CaloCalibrationHitContainer#LArCalibrationHitDeadMaterial", # "CaloCalibrationHitContainer#LArCalibrationHitDeadMaterial",
...@@ -164,13 +171,13 @@ Stream1.ItemList += ["TileHitVector#TileHitVec", ...@@ -164,13 +171,13 @@ Stream1.ItemList += ["TileHitVector#TileHitVec",
# "CaloCalibrationHitContainer#TileCalibHitInactiveCell", # "CaloCalibrationHitContainer#TileCalibHitInactiveCell",
# "CaloCalibrationHitContainer#TileCalibHitDeadMaterial" ] # "CaloCalibrationHitContainer#TileCalibHitDeadMaterial" ]
#CSC #CSC
Stream1.ItemList+=["CSCSimHitCollection#*"] Stream1.ItemList+=["CSCSimHitCollection#CSC_Hits"]
#MDT #MDT
Stream1.ItemList+=["MDTSimHitCollection#*"] Stream1.ItemList+=["MDTSimHitCollection#MDT_Hits"]
#RPC #RPC
Stream1.ItemList+=["RPCSimHitCollection#*"] Stream1.ItemList+=["RPCSimHitCollection#RPC_Hits"]
#TGC #TGC
Stream1.ItemList+=["TGCSimHitCollection#*"] Stream1.ItemList+=["TGCSimHitCollection#TGC_Hits"]
Stream1.ForceRead = True Stream1.ForceRead = True
...@@ -194,14 +201,39 @@ except: ...@@ -194,14 +201,39 @@ except:
from LArDigitization.LArDigitizationConf import LArHitFilter from LArDigitization.LArDigitizationConf import LArHitFilter
LArHitFilter = LArHitFilter("LArHitFilter") LArHitFilter = LArHitFilter("LArHitFilter")
topSequence += LArHitFilter topSequence += LArHitFilter
try:
from SGComps import AddressRemappingSvc
AddressRemappingSvc.addInputRename("LArHitContainer","LArHitEMB" ,"LArHitEMBOLD")
AddressRemappingSvc.addInputRename("LArHitContainer","LArHitEMEC","LArHitEMECOLD")
AddressRemappingSvc.addInputRename("LArHitContainer","LArHitFCAL","LArHitFCALOLD")
AddressRemappingSvc.addInputRename("LArHitContainer","LArHitHEC" ,"LArHitHECOLD")
except:
pass
#-------------------------------------------------------------- #--------------------------------------------------------------
# McEventCollection filter algorithm # McEventCollection filter algorithm
#-------------------------------------------------------------- #--------------------------------------------------------------
if hasattr(runArgs,'TruthReductionScheme'): if hasattr(runArgs,'TruthReductionScheme'):
#--------------------------------------------------------------
# Add aliases for input SimHit Collections (if possible)
#--------------------------------------------------------------
try:
from SGComps import AddressRemappingSvc
AddressRemappingSvc.addInputRename("McEventCollection","TruthEvent","TruthEventOLD")
AddressRemappingSvc.addInputRename("SiHitCollection","BCMHits","BCMHitsOLD")
AddressRemappingSvc.addInputRename("SiHitCollection","PixelHits","PixelHitsOLD")
AddressRemappingSvc.addInputRename("SiHitCollection","SCT_Hits","SCT_HitsOLD")
AddressRemappingSvc.addInputRename("TRTUncompressedHitCollection","TRTUncompressedHits","TRTUncompressedHitsOLD")
AddressRemappingSvc.addInputRename("CSCSimHitCollection","CSC_Hits","CSC_HitsOLD")
AddressRemappingSvc.addInputRename("MDTSimHitCollection","MDT_Hits","MDT_HitsOLD")
AddressRemappingSvc.addInputRename("RPCSimHitCollection","RPC_Hits","RPC_HitsOLD")
AddressRemappingSvc.addInputRename("TGCSimHitCollection","TGC_Hits","TGC_HitsOLD")
except:
pass
from McEventCollectionFilter.McEventCollectionFilterConf import McEventCollectionFilter from McEventCollectionFilter.McEventCollectionFilterConf import McEventCollectionFilter
McEventCollectionFilter = McEventCollectionFilter("McEventCollectionFilter") McEventCollectionFilter = McEventCollectionFilter("McEventCollectionFilter")
if runArgs.TruthReductionScheme != 'SingleGenEvent': if runArgs.TruthReductionScheme != 'SingleGenParticle':
filterHitLog.warning( 'Unknown TruthReductionScheme (' + runArgs.TruthReductionScheme + '). Currently just a dummy value, but please check.' ) filterHitLog.warning( 'Unknown TruthReductionScheme (' + runArgs.TruthReductionScheme + '). Currently just a dummy value, but please check.' )
## here configure the level of Truth reduction required ## here configure the level of Truth reduction required
......
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