@@ -857,11 +857,25 @@ def getDigiTaskName(det):
857857 pvfinderneeds += [FDDRECOtask ['name' ]]
858858 if isActive ('MFT' ) and isActive ('MCH' ):
859859 pvfinderneeds += [MFTMCHMATCHtask ['name' ]]
860+
861+ # Take None as default, we only add more if nothing from anchorConfig
862+ pvfinder_sources = anchorConfig .get ("o2-primary-vertexing-workflow-options" ,{}).get ("vertexing-sources" , None )
863+ pvfinder_matching_sources = anchorConfig .get ("o2-primary-vertexing-workflow-options" ,{}).get ("vertex-track-matching-sources" , None )
864+ if not pvfinder_sources :
865+ pvfinder_sources = "ITS,ITS-TPC,ITS-TPC-TRD,ITS-TPC-TOF"
866+ if isActive ("MID" ):
867+ pvfinder_sources += ",MID"
868+ pvfinderneeds += [MIDRECOtask ['name' ]]
869+ if not pvfinder_matching_sources :
870+ pvfinder_matching_sources = "ITS,MFT,TPC,ITS-TPC,MCH,MFT-MCH,TPC-TOF,TPC-TRD,ITS-TPC-TRD,ITS-TPC-TOF"
871+ if isActive ("MID" ):
872+ pvfinder_matching_sources += ",MID"
873+ pvfinderneeds += [MIDRECOtask ['name' ]]
874+
860875 PVFINDERtask = createTask (name = 'pvfinder_' + str (tf ), needs = pvfinderneeds , tf = tf , cwd = timeframeworkdir , lab = ["RECO" ], cpu = NWORKERS , mem = '4000' )
861876 PVFINDERtask ['cmd' ] = '${O2_ROOT}/bin/o2-primary-vertexing-workflow ' \
862877 + getDPL_global_options () + putConfigValuesNew (['ITSAlpideParam' ,'MFTAlpideParam' , 'pvertexer' , 'TPCGasParam' ], {"NameConf.mDirMatLUT" : ".." })
863- PVFINDERtask ['cmd' ] += ' --vertexing-sources ' + anchorConfig .get ("o2-primary-vertexing-workflow-options" ,{}).get ("vertexing-sources" , "ITS,ITS-TPC,ITS-TPC-TRD,ITS-TPC-TOF" ) \
864- + ' --vertex-track-matching-sources ' + anchorConfig .get ("o2-primary-vertexing-workflow-options" ,{}).get ("vertex-track-matching-sources" ,"ITS,MFT,TPC,ITS-TPC,MCH,MFT-MCH,TPC-TOF,TPC-TRD,ITS-TPC-TRD,ITS-TPC-TOF" )
878+ PVFINDERtask ['cmd' ] += ' --vertexing-sources ' + pvfinder_sources + ' --vertex-track-matching-sources ' + pvfinder_matching_sources
865879 workflow ['stages' ].append (PVFINDERtask )
866880
867881 if includeFullQC or includeLocalQC :
@@ -975,16 +989,25 @@ def addQCPerTF(taskName, needs, readerCommand, configFilePath, objectsFile=''):
975989 SVFINDERtask = createTask (name = 'svfinder_' + str (tf ), needs = [PVFINDERtask ['name' ]], tf = tf , cwd = timeframeworkdir , lab = ["RECO" ], cpu = svfinder_cpu , mem = '5000' )
976990 SVFINDERtask ['cmd' ] = '${O2_ROOT}/bin/o2-secondary-vertexing-workflow '
977991 SVFINDERtask ['cmd' ] += getDPL_global_options (bigshm = True ) + svfinder_threads + putConfigValuesNew (['svertexer' ], {"NameConf.mDirMatLUT" : ".." })
978- SVFINDERtask ['cmd' ] += ' --vertexing-sources ' + anchorConfig .get ("o2-secondary-vertexing-workflow-options" ,{}).get ("vertexing-sources" ,"ITS,ITS-TPC,TPC-TRD,TPC-TOF,ITS-TPC-TRD,ITS-TPC-TOF" )
992+ # Take None as default, we only add more if nothing from anchorConfig
993+ svfinder_sources = anchorConfig .get ("o2-secondary-vertexing-workflow-options" ,{}).get ("vertexing-sources" , None )
994+ if not svfinder_sources :
995+ svfinder_sources = "ITS,ITS-TPC,TPC-TRD,TPC-TOF,ITS-TPC-TRD,ITS-TPC-TOF"
996+ if isActive ("MID" ):
997+ svfinder_sources += ",MID"
998+ SVFINDERtask ['cmd' ] += ' --vertexing-sources ' + svfinder_sources
979999 workflow ['stages' ].append (SVFINDERtask )
9801000
9811001 # -----------
9821002 # produce AOD
9831003 # -----------
1004+ # TODO This needs further refinement, sources and dependencies should be constructed dynamically
1005+ aodinfosources = 'ITS,MFT,MCH,TPC,ITS-TPC,MFT-MCH,ITS-TPC-TOF,TPC-TOF,FT0,FDD,CTP,TPC-TRD,ITS-TPC-TRD,EMC'
9841006 aodneeds = [PVFINDERtask ['name' ], SVFINDERtask ['name' ], TOFRECOtask ['name' ],
9851007 FV0RECOtask ['name' ]]
9861008 if isActive ('FV0' ):
9871009 aodneeds += [ FV0RECOtask ['name' ] ]
1010+ aodinfosources += ',FV0'
9881011 if isActive ('TOF' ):
9891012 aodneeds += [ TOFRECOtask ['name' ] ]
9901013 if isActive ('TRD' ):
@@ -995,17 +1018,17 @@ def addQCPerTF(taskName, needs, readerCommand, configFilePath, objectsFile=''):
9951018 aodneeds += [ CPVRECOtask ['name' ] ]
9961019 if isActive ('PHS' ):
9971020 aodneeds += [ PHSRECOtask ['name' ] ]
1021+ if isActive ('MID' ):
1022+ aodneeds += [ MIDRECOtask ['name' ] ]
1023+ aodinfosources += ',MID'
9981024 if args .with_ZDC and isActive ('ZDC' ):
9991025 aodneeds += [ ZDCRECOtask ['name' ] ]
1026+ aodinfosources += ',ZDC'
10001027 if usebkgcache :
10011028 aodneeds += [ BKG_KINEDOWNLOADER_TASK ['name' ] ]
10021029
10031030 aod_df_id = '{0:03}' .format (tf )
10041031
1005- aodinfosources = 'ITS,MFT,MCH,TPC,ITS-TPC,MFT-MCH,ITS-TPC-TOF,TPC-TOF,FT0,FV0,FDD,CTP,TPC-TRD,ITS-TPC-TRD,EMC'
1006- if args .with_ZDC :
1007- aodinfosources += ',ZDC'
1008-
10091032 AODtask = createTask (name = 'aod_' + str (tf ), needs = aodneeds , tf = tf , cwd = timeframeworkdir , lab = ["AOD" ], mem = '4000' , cpu = '1' )
10101033 AODtask ['cmd' ] = ('' ,'ln -nfs ../bkg_Kine.root . ;' )[doembedding ]
10111034 AODtask ['cmd' ] += '[ -f AO2D.root ] && rm AO2D.root; ${O2_ROOT}/bin/o2-aod-producer-workflow --reco-mctracks-only 1 --aod-writer-keep dangling --aod-writer-resfile AO2D'
0 commit comments