ATLAS Offline Software
Loading...
Searching...
No Matches
CaloCPUOutput.h
Go to the documentation of this file.
1//
2// Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3//
4// Dear emacs, this is -*- c++ -*-
5//
6
7#ifndef CALORECGPU_CALOCPUOUTPUT_H
8#define CALORECGPU_CALOCPUOUTPUT_H
9
12#include <string>
13
16
17class CaloCell_ID;
18
29
31 public extends<AthAlgTool, CaloClusterCollectionProcessor>
32{
33 public:
34
35 CaloCPUOutput(const std::string & type, const std::string & name, const IInterface * parent);
36
38
39 virtual StatusCode initialize() override;
40
41 virtual StatusCode execute (const EventContext& ctx, xAOD::CaloClusterContainer* cluster_collection) const override;
42
43 virtual ~CaloCPUOutput() = default;
44
45 private:
46
47
52 Gaudi::Property<std::string> m_savePath{this, "SavePath", "./saved_clusters", "Path to where the files should be saved"};
53
57 Gaudi::Property<std::string> m_filePrefix{this, "FilePrefix", "", "Prefix of the saved files"};
58
62 Gaudi::Property<std::string> m_fileSuffix{this, "FileSuffix", "", "Suffix of the saved files"};
63
67 Gaudi::Property<unsigned int> m_numWidth{this, "NumberWidth", 9, "The number of digits to reserve for the events"};
68
74 Gaudi::Property<bool> m_saveCellInfo{this, "AlsoOutputCellInfo", false,
75 "Whether to output cell energies, gains, times, etc., as this information is repeated in the GPU side too."};
76
80 Gaudi::Property<bool> m_outputTags{this, "OutputCellsAsTags", true, "Whether to output cell assignment as tags instead of a list of indices per cluster."};
81
85 SG::ReadHandleKey<CaloCellContainer> m_cellsKey {this, "CellsName", "", "Name(s) of Cell Containers"};
86
90 const CaloCell_ID* m_calo_id {nullptr};
91
92};
93
94#endif //CALORECGPU_CALOCPUOUTPUT_H
Base class for cluster processing tools called from CaloClusterMaker.
Property holding a SG store/key/clid from which a ReadHandle is made.
virtual StatusCode execute(const EventContext &ctx, xAOD::CaloClusterContainer *cluster_collection) const override
Gaudi::Property< std::string > m_fileSuffix
The suffix of the saved files.
Gaudi::Property< bool > m_outputTags
Whether to output cell assignment as tags instead of a list of indices per cluster.
CaloCPUOutput(const std::string &type, const std::string &name, const IInterface *parent)
Gaudi::Property< std::string > m_filePrefix
The prefix of the saved files.
Gaudi::Property< std::string > m_savePath
The path specifying the folder to which the files should be saved.
virtual ~CaloCPUOutput()=default
SG::ReadHandleKey< CaloCellContainer > m_cellsKey
vector of names of the cell containers to use as input.
Gaudi::Property< bool > m_saveCellInfo
If true, also outputs the cell energies, times, gains, qualities and provenances.
virtual StatusCode initialize() override
const CaloCell_ID * m_calo_id
Pointer to Calo ID Helper.
Gaudi::Property< unsigned int > m_numWidth
The number of digits to reserve for the events.
Helper class for offline cell identifiers.
Definition CaloCell_ID.h:34
virtual StatusCode execute(const EventContext &ctx, xAOD::CaloClusterContainer *collection) const =0
Execute on an entire collection of clusters.
Property holding a SG store/key/clid from which a ReadHandle is made.
CaloClusterContainer_v1 CaloClusterContainer
Define the latest version of the calorimeter cluster container.