Skip to content
Snippets Groups Projects
Commit 6b615e15 authored by Eduardo Rodrigues's avatar Eduardo Rodrigues
Browse files

Merge branch 'cherry-pick-0dd24b73' into 'master'

Cherry-pick MR !155 to master branch

See merge request !157
parents 6bcc2dc2 88a5e36a
No related branches found
No related tags found
3 merge requests!1103Draft: Add AnalysisHelpers to DaVinci Stack,!167Remove Phys/KaliCalo,!157Cherry-pick MR !155 to master branch
......@@ -173,6 +173,7 @@ class DaVinci(LHCbConfigurableUser) :
if 'MDST' == self.getProp('InputType').upper() :
if not self.getProp('RootInTES') :
log.warning ('RootInTES is not specified for MDST input')
elif self.getProp('Simulation') and self.getProp('Turbo') : pass
elif self.getProp('Simulation') and not self.getProp('RootInTES') in ( '/Event/AllStreams' , '/Event/AllStreams/' ) :
log.warning ('RootInTES for MC-uDST ("%s") is not equal to "/Event/AllStreams"' % self.getProp('RootInTES') )
......@@ -191,9 +192,34 @@ class DaVinci(LHCbConfigurableUser) :
self.setOtherProps(AnalysisConf(),["DataType","Simulation","InputType","RootInTES"])
self.setOtherProps(DstConf(),["DataType","Turbo"])
self.setOtherProps(TrackSys(),["DataType"])
if self.getProp("Turbo"):
data_type = self.getProp('DataType')
if not self.isPropertySet("RootInTES") :
if self.getProp('Simulation') and '2015' == data_type :
self.setProp('RootInTES','/Event/Turbo')
else :
raise DaVinciConfigurationError ( "You must set DaVinci().RootInTES when DaVinci().Turbo is `True`")
if self.getProp('Simulation') and '2015' == data_type : pass
elif 'MDST' != self.getProp('InputType') :
log.info ("Forcing `InputType` to `'MDST'` as `Turbo` is `True`")
self.setProp ( "InputType" , "MDST")
self.setOtherProps(TurboConf(), ["DataType","Simulation","RootInTES"])
# These lines are here and not in TurboConf because different applications need to process Turbo data differently:
# Tesla has to do a bit of juggling to get the data from HLT2 to locations under a single RootInTES, whereas DaVinci doesn't.
if data_type == "2016":
# Enable the decoding of the persisted reconstruction objects
TurboConf().RunPackedDataDecoder = True
if data_type in ["2016", "2017", "2018"]:
# Enable the unpacking of the persisted reconstruction objects
TurboConf().RunPersistRecoUnpacking = True
def _analysisSeq(self) :
return GaudiSequencer('DaVinciAnalysisSeq', IgnoreFilterPassed = True)
......@@ -407,20 +433,6 @@ class DaVinci(LHCbConfigurableUser) :
if self.getProp("Simulation") :
DstConf().setProp("SimType","Full")
if self.getProp("Turbo"):
log.debug("Forcing `InputType` to `'MDST'` as `Turbo` is `True`")
self.setProp("InputType", "MDST")
if not self.getProp("RootInTES"):
raise DaVinciConfigurationError((
"You must set DaVinci().RootInTES when DaVinci().Turbo is `True`"
))
if self.getProp("DataType") == "2016":
# Enable the decoding of the persisted reconstruction objects
TurboConf().RunPackedDataDecoder = True
if self.getProp("DataType") in ["2016", "2017", "2018"]:
# Enable the unpacking of the persisted reconstruction objects
TurboConf().RunPersistRecoUnpacking = True
return inputType
################################################################################
......
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