//runs[runi]->setNoisethresholdborderADU(30);
// runs[runi]->analyzeFrame(6384);
-// runs[runi]->analyzeFrame(6604);
+// runs[runi]->analyzeFrame(6605);
// runs[runi]->analyzeFrame(675);
// runs[runi]->analyzeFrame(680);
// runs[runi]->analyzeFrame(685);
// compareHistogramClassVector.push_back(runs[runi]->histogramwoRTS->normalized);
// compareHistogramClassVector2.push_back(runs[runi]->histogramwoRTS);
compareHistogramClassVector.push_back(runs[runi]->histogram->normalized);
+ compareHistogramClassVector2.push_back(runs[runi]->histogramwoRTS->normalized);
+ runs[runi]->plot1DHistogram(runs[runi]->histogram, runs[runi]->histogramwoRTS->pixeltimefired, "", 0);
//compareHistogramClassVector.push_back(runs[runi]->histogramwoRTS);
// compareHistogramClassVector2.push_back(runs[runi]->histogramthreshold);
//compareHistogramVector.push_back(runs[runi]->histogram->normalized->calibrated->Seed);
//compareHistogramVector2.push_back(runs[runi]->histogram->normalized->Seed);
//runs[runi]->plot1DHistogram(runs[runi]->histogram->normalized->calibrated, runs[runi]->histogram->normalized->calibrated->Seed, "landau", 1);
// runs[runi]->plot1DHistogram(runs[runi]->histogramwoRTS->normalized->calibrated, runs[runi]->histogramwoRTS->normalized->calibrated->Seed, "landau", true);
- runs[runi]->plot1DHistogram(runs[runi]->histogram->normalized, runs[runi]->histogram->normalized->Seed, "gaus", true);
+// runs[runi]->plot1DHistogram(runs[runi]->histogramwoRTS->normalized->calibrated, runs[runi]->histogramwoRTS->normalized->calibrated->Sum, "gaus", true);
// // Uncomment below to do analysis without RTS pixel
// compareHistogramClassVector2.push_back(runs[runi]->histogramwoRTSthreshold);
gPad->SetGridy(1);
owntitle->Clear();
if (headerStringsVector.size() > 0) {
- cout << colorred << "Hallo1" << endlr;
owntitle->AddText(Form("%s, %s",trimRunnumberAtBegin(curhistogramclone->GetName()).Data(), headerStringsVector.at(1).Data()));
owntitle->AddText(headerStringsVector.at(2));
- cout << colorred << "Hallo2" << endlr;
}
owntitle->Draw("SAME");
same_ChipGen = kFALSE;
if (!curlabbook.matrix.EqualTo(firstlabbook.matrix)) {
same_Matrix = kFALSE;
- cout << colorred << "Not same matrix: " << curlabbook.matrix << " != " << firstlabbook.matrix << endlr;
}
if (firstlabbook.tempSens > 0) { // allow 10 % difference
if (curlabbook.tempSens > firstlabbook.tempSens*1.1 || curlabbook.tempSens < firstlabbook.tempSens*0.9)
}
}
-// if ( B < 10) CHANCE=0; // TODO remove me, buggy column 3 in Mi19, triing to ommit dirty?
-
-
-
//Begin: loop evaluate true seeds:
if(CHANCE==100)
{
if(fOrderCode=="FSBB")
+ {
+ if (B < 2 || B > fColumns-3 || A < 1 || A > fRows-2)
+ bordercluster = true;
+ else
+ bordercluster = false;
+ } else if(fOrderCode=="Pipper2") // collects very efficient in one seed
{
if (B < 2 || B > fColumns-3 || A < 1 || A > fRows-2)
bordercluster = true;
else
bordercluster = false;
}
- else //if not FSBB
+ else //if not FSBB or Pipper2
{
if (B < 2 || B > fColumns-3 || A < 2 || A > fRows-3)
bordercluster = true;
{
for(Int_t column=0; column<5; column++)
{
- if ( (row==0) && (A<2) ) { }
- else if ( (row==1) && (A<1) ) { }
- else if ( (row==3) && (A>= (fRows-1)) ) { }
+ if ( (row==0) && (A<2) ) { } // A is the global position of the HIT on the sensor
+ else if ( (row==1) && (A<1) ) { } // this procedure is to make sure, that cluster elements which are NOT part of the whole sensor
+ else if ( (row==3) && (A>= (fRows-1)) ) { } // will not crash the program, as these areas DO NOT exist (physically).
else if ( (row==4) && (A>= (fRows-2)) ) { }
else
{
if (bordercluster)
fHittedPixel[Hitlist[hit]] = -2;
- else
+ else // the hit was NOT on the border of the sensor
{
fHittedPixel[Hitlist[hit]] = 2;
for (vector<HistogramType*>::iterator curHistogramClass = HistogramClassVector.begin(); curHistogramClass != HistogramClassVector.end(); curHistogramClass++) {
cout << "Processing histograms in class: <" << colorwhite << (*curHistogramClass)->histogramdescription << colorreset << " >" << endlr;
if ((*curHistogramClass)->maskRTSpixel) {
- if (labbook.chipGen=="Mi19") {
+// if (labbook.chipGen=="Mi19") {
cout << colorwhite << " FindRTSPixelToMask():" << endlr;
FindRTSPixelToMask(*curHistogramClass);
- }
+// }
}
}
cout << "--------------------------------------------" << endl;
// HistogramTypepointer->pixeltimefiredsorted->Fill(2000);
}
}
- TH1F* pixeltimefiredWithOverflow = ShowOverflow(HistogramTypepointer->pixeltimefiredsorted);
+// TH1F* pixeltimefiredWithOverflow = ShowOverflow(HistogramTypepointer->pixeltimefiredsorted);
// Double_t const probabilities[] = {1-erf(HistogramTypepointer->RTSthreshold/sqrt(2)), 0.5, erf(HistogramTypepointer->RTSthreshold/sqrt(2))}; // sigma/2 from gaus to the left and to the right //{0.17, 0.5, 1-0.17};
// HistogramTypepointer->pixeltimefiredsorted->GetQuantiles( 3, leakagequantiles, probabilities);
if (histogramthreshold->normalized->calibrated != 0)
// if (histogramthreshold->normalized->calibrated->avgNoiseMinus < 100)
constructUpdateString(&sqlupdatequery, "Avg.Noise-", histogramthreshold->normalized->calibrated->avgNoiseMinus, 2);
- constructUpdateString(&sqlupdatequery, "CCE_1", histogram->normalized->CCE_in_Perc_1); // because histogramthreshold didn't work well with Pipper2.... why?'
- constructUpdateString(&sqlupdatequery, "CCE_25", histogram->normalized->CCE_in_Perc_25);
+ constructUpdateString(&sqlupdatequery, "CCE_1", histogramthreshold->normalized->CCE_in_Perc_1);
+ constructUpdateString(&sqlupdatequery, "CCE_25", histogramthreshold->normalized->CCE_in_Perc_25);
constructUpdateString(&sqlupdatequery, "StoN", histogramthreshold->normalized->StoN, 3);
// if (histogramthreshold->normalized->avgNoise < 100)
constructUpdateString(&sqlupdatequery, "Avg.NoiseADC", histogramthreshold->normalized->avgNoise);
if (withOverflow)
onehistogram=ShowOverflow(onehistogram);
onehistogram->Draw();
+
Double_t* parameters = (Double_t *)calloc(10, sizeof(Double_t)); // allocate 10 parameters for safety, maximum 9 used at the moment
Float_t maxValue = 0;
if (fitFuncType!="")