Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CTP: change in the task, check and trending #2454

Merged
merged 9 commits into from
Oct 22, 2024
Merged
Show file tree
Hide file tree
Changes from 4 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
24 changes: 14 additions & 10 deletions Modules/CTP/include/CTP/CTPTrendingTask.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,16 +62,20 @@ class CTPTrendingTask : public PostProcessingInterface
MetaData mMetaData;
UInt_t mTime; // this is not a specific time, used for x axis in trending plots, this name is used in all other modules, please suggest a new name if not appropriate

std::string mInputNamesDefault[5] = { "TVX", "VBA", "DMC", "EMC", "PH0" }; // ctp inputs to be trended by default, unless modified in config.json
std::string ctpinputs[49] = { " T0A", " T0C", " TVX", " TSC", " TCE", " VBA", " VOR", " VIR", " VNC", " VCH", "11", "12", " UCE", "DMC", " USC", " UVX", " U0C", " U0A", "COS", "LAS", "EMC", " PH0", "23", "24", "ZED", "ZNC", "PHL", "PHH", "PHM", "30", "31", "32", "33", "34", "35", "36", "EJ1", "EJ2", "EG1", "EG2", "DJ1", "DG1", "DJ2", "DG2", "45", "46", "47", "48", "49" }; // all ctp input names
std::string mClassNamesDefault[5] = { "CMTVX-B-NOPF", "CMVBA-B-NOPF", "CTVXDMC-B-NOPF-EMC", "CTVXEMC-B-NOPF-EMC", "CTVXPH0-B-NOPF-PHSCPV" }; // ctp classes to be trended by default, unless modified in config.json
std::string mClassNames[5] = { "", "", "", "", "" }; // the trended ctp classes will be filled in this array, either default or from config
std::string mInputNames[5] = { "", "", "", "", "" }; // the trended ctp inputs will be filled in this array, either default or from config
const int mNumberOfClasses = 5; // number of thrended ctp classes
const int mNumberOfInputs = 5; // number of thrended ctp inputs
int mClassIndex[5] = { 65, 65, 65, 65, 65 }; // indices of trended ctp classes, found in CTPconfig
int mInputIndex[5] = { 49, 49, 49, 49, 49 }; // indices of trended ctp inputs, found in CTPconfig
bool mCTPconfigFound = false; // bool telling whether the CTPconfing was already found
std::string mInputNamesDefault[5] = { "MTVX", "MVBA", "0DMC", "0EMC", "0PH0" }; // ctp inputs to be trended by default, unless modified in config.json
std::string mTrendedInputNames[5] = { "inputContentMinBias1:time", "inputContentMinBias2:time", "inputContentDMC:time", "inputContentEMC:time", "inputContentPHO:time" };
std::string mTrendedClassNames[5] = { "classContentMinBias1:time", "classContentMinBias2:time", "classContentDMC:time", "classContentEMC:time", "classContentPHO:time" };
std::string mTrendedInputRatioNames[4] = { "inputContentMinBias2/inputs", "inputContentDMC/inputs", "inputContentEMC/inputs", "inputContentPHO/inputs" };
std::string mTrendedClassRatioNames[4] = { "classContentMinBias2/classes", "classContentDMC/classes", "classContentEMC/classes", "classContentPHO/classes" };
std::string ctpinputs[49] = { "MT0A", "MT0C", "MTVX", "MTSC", "MTCE", "MVBA", "MVOR", "MVIR", "MVNC", "MVCH", "11", "12", "0UCE", "0DMC", "0USC", "0UVX", "0U0C", "0U0A", "COS", "LAS", "0EMC", "0PH0", "23", "24", "1ZED", "1ZNC", "1PHL", "1PHH", "1PHM", "30", "31", "32", "33", "34", "35", "36", "0EJ1", "0EG1", "0EJ2", "0EG2", "DJ1", "DG1", "DJ2", "DG2", "45", "46", "47", "EMBA", "49" }; // all ctp input names
Copy link
Contributor

Choose a reason for hiding this comment

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

std::string mClassNamesDefault[5] = { "CMTVX-B-NOPF", "CMVBA-B-NOPF", "CTVXDMC-B-NOPF-EMC", "CTVXEMC-B-NOPF-EMC", "CTVXPH0-B-NOPF-PHSCPV" }; // ctp classes to be trended by default, unless modified in config.json
std::string mClassNames[5] = { "", "", "", "", "" }; // the trended ctp classes will be filled in this array, either default or from config
std::string mInputNames[5] = { "", "", "", "", "" }; // the trended ctp inputs will be filled in this array, either default or from config
const int mNumberOfClasses = 5; // number of thrended ctp classes
const int mNumberOfInputs = 5; // number of thrended ctp inputs
int mClassIndex[5] = { 65, 65, 65, 65, 65 }; // indices of trended ctp classes, found in CTPconfig
int mInputIndex[5] = { 49, 49, 49, 49, 49 }; // indices of trended ctp inputs, found in CTPconfig
bool mCTPconfigFound = false; // bool telling whether the CTPconfing was already found

std::map<std::string, TObject*> mPlots;

Expand Down
1 change: 1 addition & 0 deletions Modules/CTP/include/CTP/RawDataQcTask.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ class CTPRawDataReaderTask final : public TaskInterface
int indexMB2 = -1;
static const int ninps = o2::ctp::CTP_NINPUTS + 1;
static const int nclasses = o2::ctp::CTP_NCLASSES + 1;
double mScaleInput2 = 1;
long int mTimestamp;
std::string classNames[nclasses];
int mIndexMBclass = -1; // index for the MB ctp class, which is used as scaling for the ratios
Expand Down
18 changes: 9 additions & 9 deletions Modules/CTP/include/CTP/RawDataReaderCheck.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,16 +65,16 @@ class RawDataReaderCheck : public o2::quality_control::checker::CheckInterface
TH1D* mHistClassesPrevious = nullptr; // histogram storing ctp class rates from previous cycle
TH1D* mHistInputRatioPrevious = nullptr; // histogram storing ctp input ratios to MB from previous cycle
TH1D* mHistClassRatioPrevious = nullptr;
TH1D* mHistAbsolute = nullptr; // histogram storing ctp class ratios to MB from previous cycle
std::vector<int> mVecGoodBC; // vector of good BC positions
std::vector<int> mVecMediumBC; // vector of medium BC positions, we expect a BC at this position, but inputs are below mThreshold
std::vector<int> mVecBadBC; // vector of bad BC positions, we don't expect a BC at this position, but inputs are abow mThreshold
std::vector<int> mVecIndexBad; // vector of ctp input and class indices, which had a big relative change
std::vector<int> mVecIndexMedium; // vector of ctp input and class indices, which had a relative change
std::bitset<o2::constants::lhc::LHCMaxBunches> mLHCBCs; // LHC filling scheme
const char* ctpinputs[49] = { " T0A", " T0C", " TVX", " TSC", " TCE", " VBA", " VOR", " VIR", " VNC", " VCH", "11", "12", " UCE", "DMC", " USC", " UVX", " U0C", " U0A", "COS", "LAS", "EMC", " PH0", "23", "24", "ZED", "ZNC", "PHL", "PHH", "PHM", "30", "31", "32", "33", "34", "35", "36", "EJ1", "EJ2", "EG1", "EG2", "DJ1", "DG1", "DJ2", "DG2", "45", "46", "47", "48", "49" }; // ctp input names
TH1D* mHistAbsolute = nullptr; // histogram storing ctp class ratios to MB from previous cycle
std::vector<int> mVecGoodBC; // vector of good BC positions
std::vector<int> mVecMediumBC; // vector of medium BC positions, we expect a BC at this position, but inputs are below mThreshold
std::vector<int> mVecBadBC; // vector of bad BC positions, we don't expect a BC at this position, but inputs are abow mThreshold
std::vector<int> mVecIndexBad; // vector of ctp input and class indices, which had a big relative change
std::vector<int> mVecIndexMedium; // vector of ctp input and class indices, which had a relative change
std::bitset<o2::constants::lhc::LHCMaxBunches> mLHCBCs; // LHC filling scheme
const char* ctpinputs[49] = { "T0A", "T0C", "TVX", "TSC", "TCE", "VBA", "VOR", "VIR", "VNC", "VCH", "11", "12", "UCE", "DMC", "USC", "UVX", "U0C", "U0A", "COS", "LAS", "EMC", "PH0", "23", "24", "ZED", "ZNC", "PHL", "PHH", "PHM", "30", "31", "32", "33", "34", "35", "36", "EJ1", "EJ2", "EG1", "EG2", "DJ1", "DG1", "DJ2", "DG2", "45", "46", "47", "48", "49" }; // ctp input names
Copy link
Contributor

Choose a reason for hiding this comment

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


ClassDefOverride(RawDataReaderCheck, 8);
ClassDefOverride(RawDataReaderCheck, 9);
};

} // namespace o2::quality_control_modules::ctp
Expand Down
Loading
Loading