Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions DataFormats/Detectors/ITSMFT/common/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ o2_target_root_dictionary(DataFormatsITSMFT
include/DataFormatsITSMFT/GBTCalibData.h
include/DataFormatsITSMFT/NoiseMap.h
include/DataFormatsITSMFT/TimeDeadMap.h
include/DataFormatsITSMFT/StuckPixelData.h
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One should also add

#pragma link C++ class o2::itsmft::StuckPixelData + ;

to DataFormats/Detectors/ITSMFT/common/src/ITSMFTDataFormatsLinkDef.h

include/DataFormatsITSMFT/Cluster.h
include/DataFormatsITSMFT/CompCluster.h
include/DataFormatsITSMFT/ClusterPattern.h
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
// This software is distributed under the terms of the GNU General Public
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
//
// In applying this license CERN does not waive the privileges and immunities
// granted to it by virtue of its status as an Intergovernmental Organization
// or submit itself to any jurisdiction.

/// @file StuckPixelData.h
/// @brief CCDB-serializable container for stuck (repeating) pixel error records.
///
/// Design rationale
/// ----------------
/// TTree-based storage is intentionally avoided for CCDB objects because TTree
/// branches hold internal file-pointer state; serialising an in-memory TTree
/// via CcdbApi::createObjectImage() can silently drop the last unflushed basket.
/// A plain std::vector<StuckPixelEntry> has no such issue: ROOT's TClass
/// machinery serialises it correctly via the generated dictionary, exactly as
/// it does for TimeDeadMap.

#ifndef ITSMFT_STUCKPIXELDATA_H
#define ITSMFT_STUCKPIXELDATA_H

#include <vector>
#include <cstdint>
#include <Rtypes.h> // ClassDefNV

namespace o2
{
namespace itsmft
{

/// One stuck-pixel (RepeatingPixel error) record.
struct StuckPixelEntry {
Long64_t orbit{0}; ///< first orbit of the TF in which the error was seen
uint16_t chipID{0}; ///< global chip ID (ITS only)
uint16_t row{0}; ///< pixel row
uint16_t col{0}; ///< pixel column

StuckPixelEntry() = default;
StuckPixelEntry(Long64_t o, uint16_t c, uint16_t r, uint16_t col_)
: orbit(o), chipID(c), row(r), col(col_) {}

ClassDefNV(StuckPixelEntry, 1);
};

/// CCDB payload object: a run-level collection of stuck-pixel records.
class StuckPixelData
{
public:
StuckPixelData() = default;
~StuckPixelData() = default;

void addEntry(Long64_t orbit, uint16_t chipID, uint16_t row, uint16_t col)
{
mEntries.emplace_back(orbit, chipID, row, col);
}

void clear() { mEntries.clear(); }

const std::vector<StuckPixelEntry>& getEntries() const { return mEntries; }
std::size_t size() const { return mEntries.size(); }
bool empty() const { return mEntries.empty(); }

private:
std::vector<StuckPixelEntry> mEntries;

ClassDefNV(StuckPixelData, 1);
};

} // namespace itsmft
} // namespace o2

#endif // ITSMFT_STUCKPIXELDATA_H
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,19 @@

// Flag to avoid that endOfStream and stop are both done
bool isEnded = false;
<<<<<<< HEAD
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are failed merge remnants to remove.

=======

std::string mStuckPixelFileName = "";

Check failure on line 139 in Detectors/ITSMFT/common/workflow/include/ITSMFTWorkflow/DeadMapBuilderSpec.h

View workflow job for this annotation

GitHub Actions / PR formatting / whitespace

Trailing spaces

Remove the trailing spaces at the end of the line.
TTree* mErrorTree = nullptr;

Check failure on line 140 in Detectors/ITSMFT/common/workflow/include/ITSMFTWorkflow/DeadMapBuilderSpec.h

View workflow job for this annotation

GitHub Actions / PR formatting / whitespace

Trailing spaces

Remove the trailing spaces at the end of the line.
Long64_t mErrOrbit = 0;

Check failure on line 141 in Detectors/ITSMFT/common/workflow/include/ITSMFTWorkflow/DeadMapBuilderSpec.h

View workflow job for this annotation

GitHub Actions / PR formatting / whitespace

Trailing spaces

Remove the trailing spaces at the end of the line.
UShort_t mErrChipID = 0;

Check failure on line 142 in Detectors/ITSMFT/common/workflow/include/ITSMFTWorkflow/DeadMapBuilderSpec.h

View workflow job for this annotation

GitHub Actions / PR formatting / whitespace

Trailing spaces

Remove the trailing spaces at the end of the line.
UShort_t mErrRow = 0;

Check failure on line 143 in Detectors/ITSMFT/common/workflow/include/ITSMFTWorkflow/DeadMapBuilderSpec.h

View workflow job for this annotation

GitHub Actions / PR formatting / whitespace

Trailing spaces

Remove the trailing spaces at the end of the line.
UShort_t mErrCol = 0;
>>>>>>> 5df4d36ff6 (Add ITS stuck-pixel CCDB object output)
};

6
// Create a processor spec
o2::framework::DataProcessorSpec getITSMFTDeadMapBuilderSpec(std::string datasource, bool doMFT);

Expand Down
Loading
Loading