Project
Loading...
Searching...
No Matches
cluster-writer-workflow.cxx
Go to the documentation of this file.
1
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3
// All rights not expressly granted are reserved.
4
//
5
// This software is distributed under the terms of the GNU General Public
6
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7
//
8
// In applying this license CERN does not waive the privileges and immunities
9
// granted to it by virtue of its status as an Intergovernmental Organization
10
// or submit itself to any jurisdiction.
11
12
#include <string>
13
#include <vector>
14
#include "
Framework/Variant.h
"
15
#include "
Framework/ConfigParamSpec.h
"
16
#include "
Framework/CompletionPolicyHelpers.h
"
17
#include "
DPLUtils/MakeRootTreeWriterSpec.h
"
18
#include "
CommonUtils/ConfigurableParam.h
"
19
#include "
CPVWorkflow/WriterSpec.h
"
20
21
using namespace
o2::framework
;
22
using namespace
o2::cpv
;
23
24
// we need to add workflow options before including Framework/runDataProcessing
25
void
customize
(std::vector<ConfigParamSpec>& workflowOptions)
26
{
27
std::vector<ConfigParamSpec> options{{
"disable-mc"
, VariantType::Bool,
false
, {
"Do not propagate MC labels"
}},
28
{
"configKeyValues"
, VariantType::String,
""
, {
"Semicolon separated key=value strings"
}}};
29
workflowOptions.insert(workflowOptions.end(), options.begin(), options.end());
30
}
31
32
void
customize
(std::vector<o2::framework::CompletionPolicy>& policies)
33
{
34
// ordered policies for the writers
35
policies.push_back(
CompletionPolicyHelpers::consumeWhenAllOrdered
(
".*(?:CPV|cpv).*[W,w]riter.*"
));
36
}
37
38
#include "
Framework/runDataProcessing.h
"
39
40
WorkflowSpec
defineDataProcessing
(
ConfigContext
const
& cfgc)
41
{
42
bool
useMC = !cfgc.
options
().
get
<
bool
>(
"disable-mc"
);
43
o2::conf::ConfigurableParam::updateFromString
(cfgc.
options
().
get
<std::string>(
"configKeyValues"
));
44
WorkflowSpec
specs;
45
specs.emplace_back(
o2::cpv::getClusterWriterSpec
(useMC));
46
return
specs;
47
}
WriterSpec.h
CompletionPolicyHelpers.h
ConfigParamSpec.h
ConfigurableParam.h
MakeRootTreeWriterSpec.h
Configurable generator for RootTreeWriter processor spec.
Variant.h
o2::conf::ConfigurableParam::updateFromString
static void updateFromString(std::string const &)
Definition
ConfigurableParam.cxx:433
o2::framework::ConfigContext
Definition
ConfigContext.h:24
o2::framework::ConfigContext::options
ConfigParamRegistry & options() const
Definition
ConfigContext.h:28
o2::framework::ConfigParamRegistry::get
T get(const char *key) const
Definition
ConfigParamRegistry.h:98
defineDataProcessing
WorkflowSpec defineDataProcessing(ConfigContext const &cfgc)
Definition
cluster-writer-workflow.cxx:40
customize
void customize(std::vector< ConfigParamSpec > &workflowOptions)
Definition
cluster-writer-workflow.cxx:25
o2::cpv
Definition
BadChannelMap.h:25
o2::cpv::getClusterWriterSpec
framework::DataProcessorSpec getClusterWriterSpec(bool useMC)
Definition
WriterSpec.cxx:38
o2::framework
Defining PrimaryVertex explicitly as messageable.
Definition
TFIDInfo.h:20
o2::framework::WorkflowSpec
std::vector< DataProcessorSpec > WorkflowSpec
Definition
HBFUtilsInitializer.h:39
runDataProcessing.h
o2::framework::CompletionPolicyHelpers::consumeWhenAllOrdered
static CompletionPolicy consumeWhenAllOrdered(const char *name, CompletionPolicy::Matcher matcher)
as consumeWhenAll, but ensures that records are processed with incremental timeSlice (DataHeader::sta...
Definition
CompletionPolicyHelpers.cxx:174
Detectors
CPV
workflow
src
cluster-writer-workflow.cxx
Generated on Tue Feb 25 2025 23:16:13 for Project by
1.9.8