AOD filling follows the new offline trigger schema. The method AliAODHandler::BeginEvent() resets filling of the AOD for the current event, while the ESD/AOD filters may set it back if the event passes their physics selection mask. All filters must add to their UserExec mehod lines like: // Filters must explicitely enable AOD filling in their UserExec (AG) if (!AliAnalysisManager::GetAnalysisManager()->GetOutputEventHandler()) AliFatal("Cannot run ESD filter without an output event handler"); AliAnalysisManager::GetAnalysisManager()->GetOutputEventHandler()->SetFillAOD(kTRUE); Note: Changed the logic of AliAnalysisTaskSE::fOfflineTrigger for backward compatibility: if the task does not set it (stays 0) it means all events are selected. If the mask is non 0 it is AND-ed with the current event mask (as implemented with Jan-Fiete). Again, if no event selection cuts object (like AliPhysicsSelection) is used at the level of the input handler, all events are now selected.
Added possibility to stream selected AOD events to a different AOD file. To do this inside a task: 1. Make sure an AOD handler is connected to the current analysis manager before creating the task. 2. Add in the task constructor or in LocalInit(): AliAODHandler *aodH = (AliAODHandler*)((AliAnalysisManager::GetAnalysisManager())->GetOutputEventHandler()); if (!aodH) Fatal("UserCreateOutputObjects", "No AOD handler. Aborting."); aodH->AddFilteredAOD("AliAOD.Muons.root", "MuonEvents"); // for example The pointer to the extension should not be backed-up upon adding the AOD extension, but this can be done in CreateOutputObjects() 3. Check the selection criteria in UserExec(). If fulfilled, select the event: AliAODExtension *extMuons = aodH->GetFilteredAOD("AliAOD.Muons.root"); extMuons->SelectEvent(); That is all.
Added support for creating both standard AOD and several deltaAOD's in the same ESD-based analysis. Producing a deltaAOD using AliAODHandler::SetNonStandardAOD() in an analysis on input AOD is still possible. To use the new feature: - use a standard AOD handler (no call to SetNonStandardAOD) - in the AliAnalysisTaskSE-derived task, call AddAODBranch(cname, addobj, fname) where the newly added fname is the file name where the branch(es) is(are) to be written. Added AliAnalysisTaskSE::IsStandardAOD() to check from the user code if the AOD handler is configured for standard AOD or not. Check first via AODEvent() if there is any AOD handler at all.