From: Benjamin Linnik Date: Wed, 29 Jul 2015 13:04:42 +0000 (+0200) Subject: Run analyzer: Reverted changes for FSBB (locally) X-Git-Url: https://jspc29.x-matter.uni-frankfurt.de/git/?a=commitdiff_plain;h=ed2165da682333f86d3c4bea4aafde64373e97dd;p=radhard.git Run analyzer: Reverted changes for FSBB (locally) --- diff --git a/MABS_run_analyzer/ChargeSpektrumFunctions.c b/MABS_run_analyzer/ChargeSpektrumFunctions.c index 52fe9a3..a504d01 100644 --- a/MABS_run_analyzer/ChargeSpektrumFunctions.c +++ b/MABS_run_analyzer/ChargeSpektrumFunctions.c @@ -131,11 +131,11 @@ Bool_t writeObservableToFile() { plothistogrampointer = *runs[runi]->plothistogrampointer; runnumberListe+=Form("%d_",runs[runi]->labbook.runnumber); - header+=Form("%d\t%s\t", runs[runi]->labbook.runnumber, plothistogrampointer->GetName()); + header+=Form("%d\t%s\t\t\t", runs[runi]->labbook.runnumber, plothistogrampointer->GetName()); } } } - TString filename= runs[0]->savepathresults + "/" + runnumberListe + "histograms.dat"; + TString filename= runs[0]->savepathresults + "/Excel/" + runnumberListe + "histograms.dat"; fstream* fout = new fstream(filename,ios::out); *fout << headerInfo << endl; *fout << header << endl; @@ -149,7 +149,14 @@ Bool_t writeObservableToFile() { plothistogrampointer = *runs[runi]->plothistogrampointer; TString outline; - outline=Form("%.1f\t%.1f\t",plothistogrampointer->GetBinCenter(bini),plothistogrampointer->GetBinContent(bini)); + Double_t binContentNorm=plothistogrampointer->GetBinContent(bini)/runs[runi]->labbook.frames_foundDB*10000000; + Double_t binSumme=0.0; + for(Int_t binSummei=bini;binSummeiGetNbinsX();binSummei++)//Sum up from bini beginning (cut condition for detection eff.) + { + Double_t binContentNormInSumme=plothistogrampointer->GetBinContent(binSummei)/runs[runi]->labbook.frames_foundDB*10000000; + binSumme=binSumme+binContentNormInSumme; + } + outline=Form("%.1f\t%.1f\t%.1f\t%.1f\t",plothistogrampointer->GetBinCenter(bini),plothistogrampointer->GetBinContent(bini),binContentNorm,binSumme); *fout<(fCdsmatrix, fPixels, fColumns, 0, 19); + debugStream<>(fCdsmatrix, fPixels, fColumns, 0, 39); cout<<"Hitted pixel discriminator matrix:"<(fHittedPixel, fPixels, fColumns, 1, 1); diff --git a/MABS_run_analyzer/Run.c b/MABS_run_analyzer/Run.c index 103c449..b805a68 100644 --- a/MABS_run_analyzer/Run.c +++ b/MABS_run_analyzer/Run.c @@ -98,6 +98,7 @@ Run::Run(Int_t runnumber, Int_t loopi) labbook.CCE_in_Perc_1DB = (rowsql->GetField(17) != NULL)?atoi(rowsql->GetField(17)):-1; labbook.CCE_in_Perc_25DB = (rowsql->GetField(18) != NULL)?atoi(rowsql->GetField(18)):-1; labbook.frames_foundDB = (rowsql->GetField(19) != NULL)?atoi(rowsql->GetField(19)):-1; + // labbook.frames_Analyzed = (rowsql->GetField(20) != NULL)?atoi(rowsql->GetField(20)):-1; delete res; if (labbook.chip.Length() > 0 && labbook.chipGen.Length() > 0) // versuche infos zum Chip aus der ChipDatenbank zu bekommen { @@ -283,10 +284,11 @@ Bool_t Run::analyzeRun(Bool_t force) histogramthresholdCalibrated.calibrated = histogramCalibrated.calibrated; cout << colorwhite << "calculateCCE():" << endlr; calculteCCE(); - if (labbook.source.Contains("Sr90")) { + /* if (labbook.source.Contains("Sr90")) { cout << colorwhite << "integrateSr90Spectra():" << endlr; integrateSr90Spectra(histogramthresholdCalibrated.Seed); } + */ cout << colorwhite << "updateDatabase():" << endlr; updateDatabase(); cout << colorwhite << "delete MAPS class:" << endlr; @@ -499,7 +501,9 @@ Float_t Run::stringToNumber ( string Text ) void Run::setSystemSpecificParameters() { - if (labbook.system.EqualTo("USB")) // && labbook.chipGen.EqualTo("34") ) + if (labbook.system.EqualTo("USB") && labbook.chipGen.EqualTo("Mi34") ) + systemparamcur = systemparamUSB; + else if (labbook.system.EqualTo("USB") && labbook.chipGen.EqualTo("FSBB") ) systemparamcur = systemparamUSB; else if (labbook.system.EqualTo("PXI")) // && labbook.chipGen.EqualTo("34") ) systemparamcur = systemparamPXI; @@ -514,8 +518,11 @@ void Run::setSensorInSystemParam() sensorinfostruct sensorinfoMi34USB( 8, 64 ); sensorinfostruct sensorinfoMi34PXI( 16, /* rows */ 64 /* columns */ ); sensorinfostruct sensorinfoPegasus( 8, 56 ); - if (labbook.system.EqualTo("USB")) // && labbook.chipGen.EqualTo("34") ) + sensorinfostruct sensorinfoFSBB( 8, 208 ); + if (labbook.system.EqualTo("USB") && labbook.chipGen.EqualTo("Mi34") ) sensorinfocur=sensorinfoMi34USB; + else if (labbook.system.EqualTo("USB") && labbook.chipGen.EqualTo("FSBB") ) + sensorinfocur=sensorinfoFSBB; else if (labbook.system.EqualTo("PXI")) // && labbook.chipGen.EqualTo("34") ) sensorinfocur=sensorinfoMi34PXI; else if (labbook.system.EqualTo("Pegasus")) // && labbook.chipGen.EqualTo("34") ) diff --git a/MABS_run_analyzer/Run.h b/MABS_run_analyzer/Run.h index 5c48ec3..1004f75 100644 --- a/MABS_run_analyzer/Run.h +++ b/MABS_run_analyzer/Run.h @@ -227,8 +227,8 @@ private: }; systemparam systemparamPegasus { 2800, // maxbin; - 2800/1,// nbins; - 10, //vetothreshold + 2800/2,// nbins; + 20, //vetothreshold 10, 100 }; @@ -239,7 +239,13 @@ private: 150, 150 }; - + systemparam systemparamFSBB { + 2800, // maxbin; + 2800/4,// nbins; + 25, //vetothreshold + 10, + 100 + }; Int_t* rootcolors; Int_t* rootlinestyle;