Skip to content

Commit 8146d8b

Browse files
committed
Merge remote-tracking branch 'AliceO2Group/dev' into dev
2 parents 8468c93 + 5871c4e commit 8146d8b

168 files changed

Lines changed: 2211 additions & 1160 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Common/Utils/src/FileFetcher.cxx

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
#include <memory>
2121
#include <thread>
2222
#include <chrono>
23+
#include <cstdlib>
24+
#include <locale>
2325
#include <boost/process.hpp>
2426

2527
using namespace o2::utils;
@@ -233,6 +235,20 @@ void FileFetcher::fetcher()
233235
return;
234236
}
235237

238+
// BOOST requires a locale set
239+
try {
240+
std::locale loc("");
241+
} catch (const std::exception& e) {
242+
setenv("LC_ALL", "C", 1);
243+
try {
244+
std::locale loc("");
245+
LOG(INFO) << "Setting locale";
246+
} catch (const std::exception& e) {
247+
LOG(INFO) << "Setting locale failed: " << e.what();
248+
return;
249+
}
250+
}
251+
236252
while (mRunning) {
237253
mNLoops = mNFilesProc / getNFiles();
238254
if (mNLoops > mMaxLoops) {

DataFormats/Detectors/FIT/FT0/include/DataFormatsFT0/RawEventData.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ namespace o2
3232
{
3333
namespace ft0
3434
{
35-
constexpr int Nchannels_FT0 = o2::ft0::Geometry::Nchannels;
35+
//constexpr int Nchannels_FT0 = o2::ft0::Geometry::Nchannels;
36+
static constexpr int Nchannels_FT0 = o2::ft0::Constants::sNCHANNELS_PM;
3637
using EventHeader = o2::fit::EventHeader;
3738
using EventData = o2::fit::EventData;
3839
using TCMdata = o2::fit::TCMdata;

DataFormats/Detectors/GlobalTracking/include/DataFormatsGlobalTracking/RecoContainer.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ namespace o2::mch
7171
{
7272
class TrackMCH;
7373
class ROFRecord;
74+
class ClusterStruct;
7475
} // namespace o2::mch
7576

7677
namespace o2::itsmft
@@ -397,6 +398,7 @@ struct RecoContainer {
397398
const o2::mch::TrackMCH& getMCHTrack(GTrackID gid) const { return getTrack<o2::mch::TrackMCH>(gid); }
398399
auto getMCHTracks() const { return getTracks<o2::mch::TrackMCH>(GTrackID::MCH); }
399400
auto getMCHTracksROFRecords() const { return getSpan<o2::mch::ROFRecord>(GTrackID::MCH, TRACKREFS); }
401+
auto getMCHTrackClusters() const { return getSpan<o2::mch::ClusterStruct>(GTrackID::MCH, CLUSREFS); }
400402
auto getMCHTracksMCLabels() const { return getSpan<o2::MCCompLabel>(GTrackID::MCH, MCLABELS); }
401403
// FIXME: add clusters
402404

DataFormats/Detectors/GlobalTracking/include/DataFormatsGlobalTracking/RecoContainerCreateTracksVariadic.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
#include "DataFormatsITS/TrackITS.h"
2323
#include "DataFormatsMFT/TrackMFT.h"
2424
#include "DataFormatsMCH/TrackMCH.h"
25+
#include "DataFormatsMCH/ClusterBlock.h"
2526
#include "DataFormatsMCH/ROFRecord.h"
2627
#include "DataFormatsTPC/TrackTPC.h"
2728
#include "DataFormatsTOF/Cluster.h"
@@ -152,7 +153,7 @@ void o2::globaltracking::RecoContainer::createTracksVariadic(T creator) const
152153
flagUsed(trc.getRefGlobalTrackId()); // flag seeding TPC track
153154
continue;
154155
}
155-
if (creator(trc, {i, GTrackID::TPCTRD}, t0, 1e-6)) { // assign 1ns error to BC
156+
if (creator(trc, {i, GTrackID::TPCTRD}, t0, 1e-3)) { // assign 1ns error to BC
156157
flagUsed2(i, GTrackID::TPCTRD); // flag itself (is it needed?)
157158
flagUsed(trc.getRefGlobalTrackId()); // flag seeding TPC track
158159
}

DataFormats/Detectors/GlobalTracking/src/RecoContainer.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,10 @@ void DataRequest::requestMCHTracks(bool mc)
8383
{
8484
addInput({"trackMCH", "MCH", "TRACKS", 0, Lifetime::Timeframe});
8585
addInput({"trackMCHROF", "MCH", "TRACKROFS", 0, Lifetime::Timeframe});
86+
addInput({"trackMCHTRACKCLUSTERS", "MCH", "TRACKCLUSTERS", 0, Lifetime::Timeframe});
8687
if (mc) {
8788
addInput({"trackMCHMCTR", "MCH", "TRACKLABELS", 0, Lifetime::Timeframe});
8889
}
89-
// FIXME-LA : add trackclusters
90-
// addInput({"trackMCHTRACKCLUSTERS", "MCH", "TRACKCLUSTERS", 0, Lifetime::Timeframe});
9190
requestMap["trackMCH"] = mc;
9291
}
9392

@@ -573,6 +572,7 @@ void RecoContainer::addMCHTracks(ProcessingContext& pc, bool mc)
573572
{
574573
commonPool[GTrackID::MCH].registerContainer(pc.inputs().get<gsl::span<o2::mch::TrackMCH>>("trackMCH"), TRACKS);
575574
commonPool[GTrackID::MCH].registerContainer(pc.inputs().get<gsl::span<o2::mch::ROFRecord>>("trackMCHROF"), TRACKREFS);
575+
commonPool[GTrackID::MCH].registerContainer(pc.inputs().get<gsl::span<o2::mch::ClusterStruct>>("trackMCHTRACKCLUSTERS"), CLUSREFS);
576576
if (mc) {
577577
commonPool[GTrackID::MCH].registerContainer(pc.inputs().get<gsl::span<o2::MCCompLabel>>("trackMCHMCTR"), MCLABELS);
578578
}

DataFormats/Detectors/ITSMFT/common/include/DataFormatsITSMFT/NoiseMap.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ class NoiseMap
5454
/// Get the noise level for this pixels
5555
float getNoiseLevel(int chip, int row, int col) const
5656
{
57-
if (chip > mNoisyPixels.size()) {
57+
if (chip > (int)mNoisyPixels.size()) {
5858
return 0;
5959
}
6060
const auto keyIt = mNoisyPixels[chip].find(getKey(row, col));
@@ -66,7 +66,7 @@ class NoiseMap
6666

6767
void increaseNoiseCount(int chip, int row, int col)
6868
{
69-
if (chip > mNoisyPixels.size()) {
69+
if (chip > (int)mNoisyPixels.size()) {
7070
return;
7171
}
7272
mNoisyPixels[chip][getKey(row, col)]++;
@@ -117,16 +117,16 @@ class NoiseMap
117117

118118
bool isNoisy(int chip, int row, int col) const
119119
{
120-
return chip < mNoisyPixels.size() && (mNoisyPixels[chip].find(getKey(row, col)) != mNoisyPixels[chip].end());
120+
return chip < (int)mNoisyPixels.size() && (mNoisyPixels[chip].find(getKey(row, col)) != mNoisyPixels[chip].end());
121121
}
122122

123-
bool isNoisy(int chip) const { return chip < mNoisyPixels.size() && !mNoisyPixels[chip].empty(); }
123+
bool isNoisy(int chip) const { return chip < (int)mNoisyPixels.size() && !mNoisyPixels[chip].empty(); }
124124

125125
// Methods required by the calibration framework
126126
void print();
127127
void fill(const gsl::span<const CompClusterExt> data);
128128
void merge(const NoiseMap* prev) {}
129-
const std::map<int, int>* getChipMap(int chip) const { return chip < mNoisyPixels.size() ? &mNoisyPixels[chip] : nullptr; }
129+
const std::map<int, int>* getChipMap(int chip) const { return chip < (int)mNoisyPixels.size() ? &mNoisyPixels[chip] : nullptr; }
130130

131131
private:
132132
static constexpr int SHIFT = 10, MASK = (0x1 << SHIFT) - 1;

DataFormats/Detectors/MUON/MCH/CMakeLists.txt

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,20 @@
1010
# or submit itself to any jurisdiction.
1111

1212
o2_add_library(DataFormatsMCH
13-
SOURCES src/TrackMCH.cxx src/Digit.cxx
14-
src/CTF.cxx src/ROFRecord.cxx
15-
PUBLIC_LINK_LIBRARIES O2::CommonDataFormat
13+
SOURCES src/TrackMCH.cxx
14+
src/Digit.cxx
15+
src/CTF.cxx
16+
src/ROFRecord.cxx
17+
src/ClusterBlock.cxx
18+
PUBLIC_LINK_LIBRARIES O2::CommonDataFormat
1619
O2::DetectorsCommonDataFormats)
1720

1821
o2_target_root_dictionary(DataFormatsMCH
1922
HEADERS include/DataFormatsMCH/Digit.h
2023
include/DataFormatsMCH/DsChannelGroup.h
2124
include/DataFormatsMCH/ROFRecord.h
2225
include/DataFormatsMCH/TrackMCH.h
26+
include/DataFormatsMCH/ClusterBlock.h
2327
include/DataFormatsMCH/CTF.h)
2428

2529
o2_add_executable(convert-bad-channels

Detectors/MUON/MCH/Base/include/MCHBase/ClusterBlock.h renamed to DataFormats/Detectors/MUON/MCH/include/DataFormatsMCH/ClusterBlock.h

File renamed without changes.

Detectors/MUON/MCH/Base/src/ClusterBlock.cxx renamed to DataFormats/Detectors/MUON/MCH/src/ClusterBlock.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
///
1515
/// \author Philippe Pillot, Subatech
1616

17-
#include "MCHBase/ClusterBlock.h"
17+
#include "DataFormatsMCH/ClusterBlock.h"
1818

1919
namespace o2
2020
{

DataFormats/Detectors/MUON/MCH/src/DataFormatsMCHLinkDef.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
#pragma link C++ class o2::mch::ROFRecord + ;
1919
#pragma link C++ class o2::mch::TrackMCH + ;
2020
#pragma link C++ class std::vector < o2::mch::TrackMCH> + ;
21+
#pragma link C++ class o2::mch::ClusterStruct + ;
22+
#pragma link C++ class std::vector < o2::mch::ClusterStruct> + ;
2123
#pragma link C++ class o2::mch::DsChannelId + ;
2224
#pragma link C++ class o2::mch::DsChannelGroup + ;
2325
#pragma link C++ class o2::mch::Digit + ;

0 commit comments

Comments
 (0)