Commit 083fd561 authored by Pierre-Alain Loizeau's avatar Pierre-Alain Loizeau
Browse files

[mCBM 2020] make kronos macros wrappers around standard + related fixes

- Replace un-needed calls with default description
- Synchronize time window for TOF in build_event_win.C
- Synchronize parameter folder path init in mcbm_build_and_reco.C
- Fix uncommented debug block in mcbm_event_reco.C
parent 752258d5
void build_event_win(UInt_t uRunId = 0,
Int_t nEvents = 0,
TString outDir = "data/") {
TString fileName = Form("data/unp_mcbm_%03u.root", uRunId);
Bool_t build_event_win(UInt_t uRunId = 0,
Int_t nTimeslices = 0,
TString sOutDir = "./data",
TString sInpDir = "./data") {
// ----- In- and output file names ------------------------------------
TString fileName = Form("%s/unp_mcbm_%03u.root", sInpDir.Data(), uRunId);
TString runId = TString::Format("%03u", uRunId);
TString outFile = sOutDir + "/mcbm_events_win_" + runId + ".root";
// ------------------------------------------------------------------------
if (uRunId < 692) return kFALSE;
/*
std::cout << sOutDir << std::endl << sInpDir << std::endl;
std::cout << fileName << std::endl
<< outFile << std::endl;
std::cout << uRunId << " " << nTimeslices << std::endl;
return kTRUE;
*/
// ========================================================================
// Adjust this part according to your requirements
......@@ -35,8 +49,6 @@ void build_event_win(UInt_t uRunId = 0,
FairFileSource* inputSource = new FairFileSource(fileName);
fRun->SetSource(inputSource);
TString runId = TString::Format("%03u", uRunId);
TString outFile = outDir + "/mcbm_events_win_" + runId + ".root";
FairRootFileSink* outputSink = new FairRootFileSink(outFile);
fRun->SetSink(outputSink);
......@@ -72,7 +84,7 @@ void build_event_win(UInt_t uRunId = 0,
eventBuilder->SetTriggerWindow(ECbmModuleId::kSts, -50, 100);
eventBuilder->SetTriggerWindow(ECbmModuleId::kMuch, -150, 50);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTrd, -50, 250);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTof, -150, 10);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTof, -50, 50);
eventBuilder->SetTriggerWindow(ECbmModuleId::kRich, -50, 50);
eventBuilder->SetTriggerWindow(ECbmModuleId::kPsd, -50, 50);
/// To get T0 Digis (seed + close digis) in the event
......@@ -116,7 +128,7 @@ void build_event_win(UInt_t uRunId = 0,
if (0 < uRunId)
eventBuilder->SetOutFilename(
Form("%sHistosEvtWin_%03u.root", outDir.Data(), uRunId));
Form("%s/HistosEvtWin_%03u.root", sOutDir.Data(), uRunId));
fRun->AddTask(eventBuilder);
......@@ -128,10 +140,10 @@ void build_event_win(UInt_t uRunId = 0,
// rtdb->print();
cout << "Starting run" << endl;
if (0 == nEvents) {
if (0 == nTimeslices) {
fRun->Run(0, 0); // run until end of input file
} else {
fRun->Run(0, nEvents); // process N Events
fRun->Run(0, nTimeslices); // process N Timeslices
}
// ------------------------------------------------------------------------
......@@ -164,4 +176,6 @@ void build_event_win(UInt_t uRunId = 0,
cout << " Test passed" << endl;
cout << " All ok " << endl;
return kTRUE;
}
void build_event_win_kronos(UInt_t uRunIdx = 0,
Int_t nEvents = 0,
TString outDir = "data/") {
#include "build_event_win.C"
Bool_t build_event_win_kronos(UInt_t uRunIdx = 28,
Int_t nTimeslices = 0,
TString sOutDir = "./data",
TString sInpDir = "/lustre/cbm/users/ploizeau/mcbm2020/"
"unp_evt_data_7f229b3f_20201103") {
UInt_t uRunId = 0;
TString fileName = "data/unp_mcbm_0.root";
if (99999 != uRunIdx) {
std::vector<UInt_t> vuListRunId = {
692, 698, 702, 704, 705, 706, 707, // 7 => 0 - 6
......@@ -13,183 +17,23 @@ void build_event_win_kronos(UInt_t uRunIdx = 0,
841, 846, 849, // 3 => 30 - 32
850, 851, 852, 854, 855, 856, 857, 858, 859, // 9 => 33 - 41
860, 861, 862, 863, 864, 865, 866 // 7 => 42 - 48
/*
/// With runs < 1 min due to missmatch!
811, 812, 816, 817, 818, 819, // 6 => 14 - 19
820, 821, 822, 824, 826, 827, 828, 829, // 8 => 20 - 27
830, 831, 836, 839, // 4 => 28 - 31
840, 841, 842, 844, 845, 846, 848, 849, // 8 => 32 - 39
850, 851, 852, 854, 855, 856, 857, 858, 859, // 9 => 40 - 48
860, 861, 862, 863, 864, 865, 866 // 7 => 49 - 55
*/
/*
/// With runs < 1 min due to missmatch!
811, 812, 816, 817, 818, 819, // 6 => 14 - 19
820, 821, 822, 824, 826, 827, 828, 829, // 8 => 20 - 27
830, 831, 836, 839, // 4 => 28 - 31
840, 841, 842, 844, 845, 846, 848, 849, // 8 => 32 - 39
850, 851, 852, 854, 855, 856, 857, 858, 859, // 9 => 40 - 48
860, 861, 862, 863, 864, 865, 866 // 7 => 49 - 55
*/
};
if (vuListRunId.size() <= uRunIdx) return kFALSE;
uRunId = vuListRunId[uRunIdx];
//fileName = Form("data/unp_mcbm_%03u.root", uRunId);
fileName = Form("/lustre/cbm/users/ploizeau/mcbm2020/"
"unp_evt_data_7f229b3f_20201103/unp_mcbm_%i.root",
uRunId);
} // if( 99999 != uRunIdx )
if (uRunId < 692 && 0 != uRunId) return kFALSE;
// ========================================================================
// Adjust this part according to your requirements
// Verbosity level (0=quiet, 1=event level, 2=track level, 3=debug)
// Int_t iVerbose = 1;
// --- Set log output levels
FairLogger::GetLogger();
gLogger->SetLogScreenLevel("INFO");
// gLogger->SetLogScreenLevel("DEBUG");
gLogger->SetLogVerbosityLevel("MEDIUM");
// MC file
TString srcDir = gSystem->Getenv("VMCWORKDIR");
// ----- Timer --------------------------------------------------------
TStopwatch timer;
timer.Start();
// ------------------------------------------------------------------------
// ----- Analysis run --------------------------------------------------
// FairRunOnline *fRun= new FairRunOnline();
FairRunAna* fRun = new FairRunAna();
fRun->SetEventHeaderPersistence(kFALSE);
FairFileSource* inputSource = new FairFileSource(fileName);
fRun->SetSource(inputSource);
TString runId = TString::Format("%03u", uRunId);
TString outFile = outDir + "/mcbm_events_win_" + runId + ".root";
FairRootFileSink* outputSink = new FairRootFileSink(outFile);
fRun->SetSink(outputSink);
// Define output file for FairMonitor histograms
// TString monitorFile{outFile};
// monitorFile.ReplaceAll("qa","qa.monitor");
FairMonitor::GetMonitor()->EnableMonitor(kTRUE);
// FairMonitor::GetMonitor()->EnableMonitor(kFALSE);
// ------------------------------------------------------------------------
// CbmMcbm2019TimeWinEventBuilder* eventBuilder = new CbmMcbm2019TimeWinEventBuilder();
CbmMcbm2019TimeWinEventBuilderTask* eventBuilder =
new CbmMcbm2019TimeWinEventBuilderTask();
eventBuilder->SetFillHistos(kTRUE);
eventBuilder->SetEventOverlapMode(EOverlapMode::NoOverlap);
// eventBuilder->SetEventOverlapMode(EOverlapMode::MergeOverlap);
// eventBuilder->SetEventOverlapMode(EOverlapMode::AllowOverlap);
/*
* Available Pre-defined detectors:
* kEventBuilderDetSts
* kEventBuilderDetMuch
* kEventBuilderDetTrd
* kEventBuilderDetTof
* kEventBuilderDetRich
* kEventBuilderDetPsd
* kEventBuilderDetT0
*/
/// Change the selection window limits for T0 as ref
eventBuilder->SetTriggerWindow(ECbmModuleId::kSts, -50, 100);
eventBuilder->SetTriggerWindow(ECbmModuleId::kMuch, -150, 50);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTrd, -50, 250);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTof, -150, 10);
eventBuilder->SetTriggerWindow(ECbmModuleId::kRich, -50, 50);
eventBuilder->SetTriggerWindow(ECbmModuleId::kPsd, -50, 50);
/// To get T0 Digis (seed + close digis) in the event
eventBuilder->SetTriggerWindow(ECbmModuleId::kT0, -1, 10);
/*
/// Use TOF as reference
eventBuilder->SetReferenceDetector( kEventBuilderDetTof );
eventBuilder->AddDetector(kEventBuilderDetT0);
/// Change the selection window limits for TOF as ref
/// => Should always be after changes of detector lists!
eventBuilder->SetTriggerWindow(ECbmModuleId::kT0, -150, 0);
eventBuilder->SetTriggerWindow(ECbmModuleId::kSts, -50, 100);
eventBuilder->SetTriggerWindow(ECbmModuleId::kMuch, -50, 200);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTrd, -50, 300);
eventBuilder->SetTriggerWindow(ECbmModuleId::kTof, 0, 60);
eventBuilder->SetTriggerWindow(ECbmModuleId::kRich, -100, 150);
eventBuilder->SetTriggerWindow(ECbmModuleId::kPsd, -200, 50);
*/
/// Change the trigger requirements
/// => Should always be after changes of detector lists!
/// --- Minimum
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kT0, 1);
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kSts, 0);
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kMuch, 0);
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kTrd, 0);
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kTof, 10);
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kRich, 0);
eventBuilder->SetTriggerMinNumber(ECbmModuleId::kPsd, 0);
/// --- Maximum (-1 to disable cut)
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kT0, -1);
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kSts, -1);
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kMuch, -1);
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kTrd, -1);
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kTof, -1);
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kRich, -1);
eventBuilder->SetTriggerMaxNumber(ECbmModuleId::kPsd, -1);
if (0 < uRunId)
eventBuilder->SetOutFilename(
Form("%sHistosEvtWin_%03u.root", outDir.Data(), uRunId));
fRun->AddTask(eventBuilder);
// ----- Intialise and run --------------------------------------------
fRun->Init();
// rtdb->setOutput(parIo1);
// rtdb->saveOutput();
// rtdb->print();
cout << "Starting run" << endl;
if (0 == nEvents) {
fRun->Run(0, 0); // run until end of input file
} else {
fRun->Run(0, nEvents); // process N Events
}
// ------------------------------------------------------------------------
// ----- Finish -------------------------------------------------------
timer.Stop();
Double_t rtime = timer.RealTime();
Double_t ctime = timer.CpuTime();
cout << endl << endl;
cout << "Macro finished succesfully." << endl;
cout << "Real time " << rtime << " s, CPU time " << ctime << " s" << endl;
cout << endl;
// ------------------------------------------------------------------------
// Extract the maximal used memory an add is as Dart measurement
// This line is filtered by CTest and the value send to CDash
FairSystemInfo sysInfo;
Float_t maxMemory = sysInfo.GetMaxMemory();
cout << "<DartMeasurement name=\"MaxMemory\" type=\"numeric/double\">";
cout << maxMemory;
cout << "</DartMeasurement>" << endl;
Float_t cpuUsage = ctime / rtime;
cout << "<DartMeasurement name=\"CpuLoad\" type=\"numeric/double\">";
cout << cpuUsage;
cout << "</DartMeasurement>" << endl;
FairMonitor* tempMon = FairMonitor::GetMonitor();
tempMon->Print();
cout << " Test passed" << endl;
cout << " All ok " << endl;
return build_event_win(uRunId, nTimeslices, sOutDir, sInpDir);
}
......@@ -7,9 +7,10 @@
// --------------------------------------------------------------------------
void mcbm_build_and_reco(UInt_t uRunId = 831,
Int_t nTimeslices = 300,
TString outDir = "data/") {
Bool_t mcbm_build_and_reco(UInt_t uRunId = 831,
Int_t nTimeslices = 0,
TString sInpDir = "./data",
TString sOutDir = "./data") {
// ========================================================================
......@@ -25,16 +26,29 @@ void mcbm_build_and_reco(UInt_t uRunId = 831,
TString myName = "mcbm_reco"; // this macro's name for screen output
TString srcDir = gSystem->Getenv("VMCWORKDIR"); // top source directory
TString paramDir = srcDir + "/macro/beamtime/mcbm2020/";
TString parDir = srcDir + "/parameters";
// ------------------------------------------------------------------------
// ----- In- and output file names ------------------------------------
TString inFile = Form("./data/unp_mcbm_%i.root", uRunId);
TString parFileIn = Form("./data/unp_mcbm_params_%i.root", uRunId);
TString parFileOut = Form("./data/reco_mcbm_evt_win_params_%u.root", uRunId);
TString outFile = Form("./data/reco_mcbm_evt_win_%u.root", uRunId);
TString inFile = sInpDir + Form("/unp_mcbm_%03u.root", uRunId);
TString parFileIn = sInpDir + Form("/unp_mcbm_params_%03u.root", uRunId);
TString parFileOut = sOutDir + Form("/reco_mcbm_evt_win_params_%03u.root",
uRunId);
TString outFile = sOutDir + Form("/reco_mcbm_evt_win_%03u.root", uRunId);
// ------------------------------------------------------------------------
/*
std::cout << sInpDir << std::endl << sOutDir << std::endl;
std::cout << inFile << std::endl
<< parFileIn << std::endl
<< parFileOut << std::endl
<< outFile << std::endl;
std::cout << uRunId << " " << nTimeslices << std::endl;
return kTRUE;
*/
// --- Load the geometry setup ----
// This is currently only required by the TRD (parameters)
std::string geoSetupTag = "mcbm_beam_2020_03";
......@@ -96,8 +110,8 @@ void mcbm_build_and_reco(UInt_t uRunId = 831,
* kEventBuilderDetT0
*/
/// Use T0 as reference
eventBuilder->SetReferenceDetector(kEventBuilderDetT0);
eventBuilder->AddDetector(kEventBuilderDetTof);
/// The default (hardcoded) settings are T0 as reference detector and
/// STS, MUCH, TRD, TOF, RICH and PSD as selected detectors
/// Change the selection window limits for T0 as ref
eventBuilder->SetTriggerWindow(ECbmModuleId::kSts, -50, 100);
......@@ -147,7 +161,7 @@ void mcbm_build_and_reco(UInt_t uRunId = 831,
if (0 < uRunId)
eventBuilder->SetOutFilename(
Form("%sHistosEvtWin_%03u.root", outDir.Data(), uRunId));
Form("%sHistosEvtWin_%03u.root", sOutDir.Data(), uRunId));
run->AddTask(eventBuilder);
// ------------------------------------------------------------------------
......@@ -198,8 +212,6 @@ void mcbm_build_and_reco(UInt_t uRunId = 831,
// ----- Local reconstruction in MUCH ---------------------------------
Int_t flag = 1;
TString parDir =
TString(gSystem->Getenv("VMCWORKDIR")) + TString("/parameters");
TString muchDigiFile(
parDir + "/much/much_v19c_mcbm_digi_sector.root"); // MUCH digi file
CbmMuchFindHitsGem* muchFindHits =
......@@ -247,6 +259,7 @@ void mcbm_build_and_reco(UInt_t uRunId = 831,
std::cout << "-I- : Added task " << trdHit->GetName() << std::endl;
// ------------------------------------------------------------------------
// ----- Local reconstruction in TOF ----------------------------------
// ------------------------------------------------------------------------
// TOF defaults
......@@ -552,4 +565,6 @@ void mcbm_build_and_reco(UInt_t uRunId = 831,
/// --- Screen output for automatic tests
std::cout << " Test passed" << std::endl;
std::cout << " All ok " << std::endl;
return kTRUE;
}
......@@ -6,10 +6,13 @@
//
// --------------------------------------------------------------------------
void mcbm_event_reco(Int_t runId = 831, Int_t nTimeslices = -1) {
Bool_t mcbm_event_reco(UInt_t uRunId = 831,
Int_t nTimeslices = 0,
TString sInpDir = "./data",
TString sOutDir = "./data") {
// --- Logger settings ----------------------------------------------------
TString logLevel = "WARN";
TString logLevel = "INFO";
TString logVerbosity = "LOW";
// ------------------------------------------------------------------------
......@@ -23,12 +26,24 @@ void mcbm_event_reco(Int_t runId = 831, Int_t nTimeslices = -1) {
// ----- In- and output file names ------------------------------------
TString inFile = Form("./data/unp_mcbm_%i.root", runId);
TString parFileIn = Form("./data/unp_mcbm_params_%i.root", runId);
TString parFileOut = Form("./data/reco_mcbm_event_params_%i.root", runId);
TString outFile = Form("./data/reco_mcbm_event_%i.root", runId);
TString inFile = sInpDir + Form("/unp_mcbm_%03u.root", uRunId);
TString parFileIn = sInpDir + Form("/unp_mcbm_params_%03u.root", uRunId);
TString parFileOut = sOutDir + Form("/reco_mcbm_event_params_%03u.root",
uRunId);
TString outFile = sOutDir + Form("/reco_mcbm_event_%03u.root", uRunId);
// ------------------------------------------------------------------------
/*
std::cout << sInpDir << std::endl << sOutDir << std::endl;
std::cout << inFile << std::endl
<< parFileIn << std::endl
<< parFileOut << std::endl
<< outFile << std::endl;
std::cout << uRunId << " " << nTimeslices << std::endl;
return kTRUE;
*/
// --- Load the geometry setup ----
// This is currently only required by the TRD (parameters)
std::string geoSetupTag = "mcbm_beam_2020_03";
......@@ -477,4 +492,6 @@ void mcbm_event_reco(Int_t runId = 831, Int_t nTimeslices = -1) {
/// --- Screen output for automatic tests
std::cout << " Test passed" << std::endl;
std::cout << " All ok " << std::endl;
return kTRUE;
}
......@@ -5,8 +5,10 @@
//
// --------------------------------------------------------------------------
void mcbm_reco(Int_t runId = 831, Int_t nTimeslices = 0) {
Bool_t mcbm_reco(UInt_t uRunId = 831,
Int_t nTimeslices = 0,
TString sInpDir = "./data",
TString sOutDir = "./data") {
// --- Logger settings ----------------------------------------------------
TString logLevel = "INFO";
......@@ -23,12 +25,23 @@ void mcbm_reco(Int_t runId = 831, Int_t nTimeslices = 0) {
// ----- In- and output file names ------------------------------------
TString inFile = Form("./data/unp_mcbm_%i.root", runId);
TString parFileIn = Form("./data/unp_mcbm_params_%i.root", runId);
TString parFileOut = Form("./data/reco_mcbm_params_%i.root", runId);
TString outFile = Form("./data/reco_mcbm_%i.root", runId);
TString inFile = sInpDir + Form("/unp_mcbm_%03u.root", uRunId);
TString parFileIn = sInpDir + Form("/unp_mcbm_params_%03u.root", uRunId);
TString parFileOut = sOutDir + Form("/reco_mcbm_params_%03u.root", uRunId);
TString outFile = sOutDir + Form("/reco_mcbm_%03u.root", uRunId);
// ------------------------------------------------------------------------
/*
std::cout << sInpDir << std::endl << sOutDir << std::endl;
std::cout << inFile << std::endl
<< parFileIn << std::endl
<< parFileOut << std::endl
<< outFile << std::endl;
std::cout << uRunId << " " << nTimeslices << std::endl;
return kTRUE;
*/
// --- Load the geometry setup ----
// This is currently only required by the TRD (parameters)
std::string geoSetupTag = "mcbm_beam_2020_03";
......@@ -287,4 +300,6 @@ void mcbm_reco(Int_t runId = 831, Int_t nTimeslices = 0) {
/// --- Screen output for automatic tests
std::cout << " Test passed" << std::endl;
std::cout << " All ok " << std::endl;
return kTRUE;
}
......@@ -5,290 +5,42 @@
//
// --------------------------------------------------------------------------
void mcbm_reco_kronos(Int_t runId = 831, Int_t nTimeslices = 0) {
// --- Logger settings ----------------------------------------------------
TString logLevel = "INFO";
TString logVerbosity = "LOW";
// ------------------------------------------------------------------------
// ----- Environment --------------------------------------------------
TString myName = "mcbm_reco"; // this macro's name for screen output
TString srcDir = gSystem->Getenv("VMCWORKDIR"); // top source directory
TString paramDir = srcDir + "/macro/beamtime/mcbm2020/";
TString parDir = srcDir + "/parameters";
// ------------------------------------------------------------------------
// ----- In- and output file names ------------------------------------
TString inFile = Form("/lustre/cbm/users/ploizeau/mcbm2020/"
"unp_evt_data_7f229b3f_20201103/unp_mcbm_%i.root",
runId);
TString parFileIn =
Form("/lustre/cbm/users/ploizeau/mcbm2020/unp_evt_data_7f229b3f_20201103/"
"unp_mcbm_params_%i.root",
runId);
TString parFileOut = Form("./data/reco_mcbm_params_%i.root", runId);
TString outFile = Form("./data/reco_mcbm_%i.root", runId);
// ------------------------------------------------------------------------
// --- Load the geometry setup ----
// This is currently only required by the TRD (parameters)
std::string geoSetupTag = "mcbm_beam_2020_03";
TString geoFile =
paramDir + geoSetupTag.data() + ".geo.root"; // Created in sim. run
CbmSetup* geoSetup = CbmSetup::Instance();
geoSetup->LoadSetup(geoSetupTag.data());
TList* parFileList = new TList();
// ------------------------------------------------------------------------
// ----- Timer --------------------------------------------------------
TStopwatch timer;
timer.Start();
// ------------------------------------------------------------------------
// ----- FairRunAna ---------------------------------------------------
FairRunAna* run = new FairRunAna();
FairFileSource* inputSource = new FairFileSource(inFile);
run->SetSource(inputSource);
FairRootFileSink* outputSink = new FairRootFileSink(outFile);
run->SetSink(outputSink);
run->SetGeomFile(geoFile);
// Define output file for FairMonitor histograms
TString monitorFile {outFile};
monitorFile.ReplaceAll("reco", "reco.monitor");
FairMonitor::GetMonitor()->EnableMonitor(kTRUE, monitorFile);
// ------------------------------------------------------------------------
// ----- Logger settings ----------------------------------------------
FairLogger::GetLogger()->SetLogScreenLevel(logLevel.Data());
FairLogger::GetLogger()->SetLogVerbosityLevel(logVerbosity.Data());
// ------------------------------------------------------------------------
// ----- Reconstruction tasks -----------------------------------------
// ----- Local reconstruction in MUCH ---------------------------------
Int_t flag = 1;
TString muchDigiFile(
parDir + "/much/much_v19c_mcbm_digi_sector.root"); // MUCH digi file
CbmMuchFindHitsGem* muchFindHits =
new CbmMuchFindHitsGem(muchDigiFile.Data(), flag);
muchFindHits->SetBeamTimeDigi(kTRUE);
run->AddTask(muchFindHits);
std::cout << "-I- : Added task " << muchFindHits->GetName() << std::endl;
//--------------------------------------------------------
// ----- Local reconstruction in STS ----------------------------------
CbmRecoSts* recoSts = new CbmRecoSts();
//recoSts->SetTimeCutDigisAbs( 20 );// cluster finder: time cut in ns
//recoSts->SetTimeCutClustersAbs(20.); // hit finder: time cut in ns
// ASIC params: #ADC channels, dyn. range, threshold, time resol., dead time,
// noise RMS, zero-threshold crossing rate
auto parAsic =
new CbmStsParAsic(32, 75000., 3000., 5., 800., 1000., 3.9789e-3);
// Module params: number of channels, number of channels per ASIC
auto parMod = new CbmStsParModule(2048, 128);
parMod->SetAllAsics(*parAsic);
recoSts->UseModulePar(parMod);
// Sensor params
auto sensorPar = new CbmStsParSensor(CbmStsSensorClass::kDssdStereo);
sensorPar->SetPar(0, 6.2092); // Extension in x
sensorPar->SetPar(1, 6.2); // Extension in y
sensorPar->SetPar(2, 0.03); // Extension in z
sensorPar->SetPar(3, 5.9692); // Active size in y
sensorPar->SetPar(4, 1024.); // Number of strips front side
sensorPar->SetPar(5, 1024.); // Number of strips back side
sensorPar->SetPar(6, 0.0058); // Strip pitch front side
sensorPar->SetPar(7, 0.0058); // Strip pitch back side
sensorPar->SetPar(8, 7.5); // Stereo angle front side
sensorPar->SetPar(9, 0.0); // Stereo angle back side
recoSts->UseSensorPar(sensorPar);
// Sensor conditions: full depletion voltage, bias voltage, temperature,
// coupling capacitance, inter-strip capacitance
auto sensorCond = new CbmStsParSensorCond(70., 140., 268., 17.5, 1.);
recoSts->UseSensorCond(sensorCond);
run->AddTask(recoSts);
std::cout << "-I- : Added task " << recoSts->GetName() << std::endl;
// ------------------------------------------------------------------------