From 6c870207b483004f4a40c082ad1fb2b5e48a2307 Mon Sep 17 00:00:00 2001 From: laphecet Date: Mon, 19 Oct 2009 22:31:17 +0000 Subject: [PATCH] Update of preprocessors. - AliMUONVSubprocessor::Initialize method now returns a boolean to know whether the init was ok or not (previously the preprocessor could announce Init OK while it was not...) - Adding the handling of the tracker configuration in the Pedestal subprocessor, creating a new OCDB object = MUON/Calib/Config. This object is around 85 KBytes, and hopefully will change rarely (only when we have to remove part of the detector from the readout for whatever serious reason). - Allow mchview to plot the new MUON/Calib/Config object. --- MUON/AliMUON2DStoreValidator.cxx | 27 ++-- MUON/AliMUON2DStoreValidator.h | 7 +- MUON/AliMUONCalibrationData.cxx | 37 +++++- MUON/AliMUONCalibrationData.h | 12 +- MUON/AliMUONGMSSubprocessor.cxx | 3 +- MUON/AliMUONGMSSubprocessor.h | 2 +- MUON/AliMUONGainSubprocessor.cxx | 7 +- MUON/AliMUONGainSubprocessor.h | 2 +- MUON/AliMUONMchViewApplication.cxx | 8 +- MUON/AliMUONMchViewApplication.h | 2 +- MUON/AliMUONOccupancySubprocessor.cxx | 7 +- MUON/AliMUONOccupancySubprocessor.h | 2 +- MUON/AliMUONPainterDataSourceFrame.cxx | 1 + MUON/AliMUONPedestalEventGenerator.cxx | 4 +- MUON/AliMUONPedestalSubprocessor.cxx | 101 +++++++++++++-- MUON/AliMUONPedestalSubprocessor.h | 9 +- MUON/AliMUONPreprocessor.cxx | 6 +- MUON/AliMUONPreprocessor.h | 3 + MUON/AliMUONTrackerIO.cxx | 133 ++++++++++++++++++++ MUON/AliMUONTrackerIO.h | 4 + MUON/AliMUONTrackerOCDBDataMaker.cxx | 7 ++ MUON/AliMUONTriggerSubprocessor.cxx | 9 +- MUON/AliMUONTriggerSubprocessor.h | 2 +- MUON/AliMUONVSubprocessor.cxx | 7 +- MUON/AliMUONVSubprocessor.h | 2 +- MUON/TestMUONPreprocessor.C | 168 +++++++++++++++++++------ 26 files changed, 482 insertions(+), 90 deletions(-) diff --git a/MUON/AliMUON2DStoreValidator.cxx b/MUON/AliMUON2DStoreValidator.cxx index de5a02c2728..dc7c0397459 100644 --- a/MUON/AliMUON2DStoreValidator.cxx +++ b/MUON/AliMUON2DStoreValidator.cxx @@ -296,19 +296,22 @@ AliMUON2DStoreValidator::Report(TList& lines, const TObjArray& chambers) //_____________________________________________________________________________ TObjArray* -AliMUON2DStoreValidator::Validate(const AliMUONVStore& store) +AliMUON2DStoreValidator::Validate(const AliMUONVStore& store, + AliMUONVStore* config) { /// Validate the store. Check only the presence of all manus (i.e. - /// check nothing about the values themselves) + /// check nothing about the values themselves). + /// Absence of manus which are not in the config is considered as normal. Bool_t (*kCheck)(const AliMUONVCalibParam&,Int_t) = 0x0; - return Validate(store,kCheck); + return Validate(store,kCheck,config); } //_____________________________________________________________________________ TObjArray* AliMUON2DStoreValidator::Validate(const AliMUONVStore& store, - Bool_t (*check)(const AliMUONVCalibParam&,Int_t)) + Bool_t (*check)(const AliMUONVCalibParam&,Int_t), + AliMUONVStore* config) { /// Validate the store. /// The check method is used to decide if a store content value @@ -331,7 +334,11 @@ AliMUON2DStoreValidator::Validate(const AliMUONVStore& store, if (!test) { // completely missing manu - AddMissingManu(detElemId,manuId); + if ( !config || ( config && config->FindObject(detElemId,manuId ) ) ) + { + // manu is in the config but not in the store : that's an error + AddMissingManu(detElemId,manuId); + } } else { @@ -358,7 +365,8 @@ AliMUON2DStoreValidator::Validate(const AliMUONVStore& store, //_____________________________________________________________________________ TObjArray* AliMUON2DStoreValidator::Validate(const AliMUONVStore& store, - Float_t invalidFloatValue) + Float_t invalidFloatValue, + AliMUONVStore* config) { /// Validate the store. /// The invalidFloatValue is used to decide if a store content value @@ -379,8 +387,11 @@ AliMUON2DStoreValidator::Validate(const AliMUONVStore& store, static_cast(store.FindObject(detElemId,manuId)); if (!test) { - // completely missing manu - AddMissingManu(detElemId,manuId); + if ( !config || ( config && config->FindObject(detElemId,manuId ) ) ) + { + // completely missing manu + AddMissingManu(detElemId,manuId); + } } else { diff --git a/MUON/AliMUON2DStoreValidator.h b/MUON/AliMUON2DStoreValidator.h index 4943f79ddfe..61cf1c55199 100644 --- a/MUON/AliMUON2DStoreValidator.h +++ b/MUON/AliMUON2DStoreValidator.h @@ -29,12 +29,13 @@ public: AliMUON2DStoreValidator(); virtual ~AliMUON2DStoreValidator(); - TObjArray* Validate(const AliMUONVStore& store, Float_t invalidFloatValue); + TObjArray* Validate(const AliMUONVStore& store, Float_t invalidFloatValue, AliMUONVStore* config=0x0); - TObjArray* Validate(const AliMUONVStore& store); + TObjArray* Validate(const AliMUONVStore& store, AliMUONVStore* config=0x0); TObjArray* Validate(const AliMUONVStore& store, - Bool_t (*check)(const AliMUONVCalibParam&,Int_t)); + Bool_t (*check)(const AliMUONVCalibParam&,Int_t), + AliMUONVStore* config=0x0); /// Return statuses AliMUONVStore* GetStatus() const { return fStatus; } diff --git a/MUON/AliMUONCalibrationData.cxx b/MUON/AliMUONCalibrationData.cxx index d3eb1ec0cb5..ef68fda7f40 100644 --- a/MUON/AliMUONCalibrationData.cxx +++ b/MUON/AliMUONCalibrationData.cxx @@ -75,7 +75,8 @@ fTriggerEfficiency(0x0), fCapacitances(0x0), fNeighbours(0x0), fOccupancyMap(0x0), -fRejectList(0x0) +fRejectList(0x0), +fConfig(0x0) { /// Default ctor. @@ -100,6 +101,7 @@ fRejectList(0x0) TriggerEfficiency(); Capacitances(); Neighbours(); + Config(); } } @@ -245,6 +247,14 @@ AliMUONCalibrationData::CreatePedestals(Int_t runNumber, Int_t* startOfValidity) return dynamic_cast(CreateObject(runNumber,"MUON/Calib/Pedestals",startOfValidity)); } +//_____________________________________________________________________________ +AliMUONVStore* +AliMUONCalibrationData::CreateConfig(Int_t runNumber, Int_t* startOfValidity) +{ + /// Create a new config store from the OCDB for a given run + return dynamic_cast(CreateObject(runNumber,"MUON/Calib/Config",startOfValidity)); +} + //_____________________________________________________________________________ AliMUONRegionalTriggerConfig* @@ -429,6 +439,19 @@ AliMUONCalibrationData::Pedestals() const return fPedestals; } +//_____________________________________________________________________________ +AliMUONVStore* +AliMUONCalibrationData::Config() const +{ + /// Return config + + if (!fConfig) + { + fConfig = CreateConfig(fRunNumber); + } + return fConfig; +} + //_____________________________________________________________________________ AliMUONVCalibParam* AliMUONCalibrationData::Pedestals(Int_t detElemId, Int_t manuId) const @@ -455,6 +478,7 @@ AliMUONCalibrationData::Print(Option_t*) const cout << "RunNumber " << RunNumber() << " fGains=" << fGains << " fPedestals=" << fPedestals + << " fConfig=" << fConfig << " fHV=" << fHV << " fTriggerDCS=" << fTriggerDCS << " fLocalTriggerBoardMasks=" << fLocalTriggerBoardMasks @@ -512,6 +536,8 @@ AliMUONCalibrationData::Reset() { /// Reset all data + delete fConfig; + fConfig = 0x0; delete fPedestals; fPedestals = 0x0; delete fGains; @@ -615,6 +641,15 @@ AliMUONCalibrationData::Check(Int_t runNumber) { AliInfoClass("Pedestals read OK"); } + + if ( ! CreateConfig(runNumber) ) + { + AliErrorClass("Could not read config"); + } + else + { + AliInfoClass("Config read OK"); + } if ( ! CreateRegionalTriggerConfig(runNumber) ) { diff --git a/MUON/AliMUONCalibrationData.h b/MUON/AliMUONCalibrationData.h index a8b912390f3..5541af3ac98 100644 --- a/MUON/AliMUONCalibrationData.h +++ b/MUON/AliMUONCalibrationData.h @@ -70,6 +70,9 @@ public: /// Create a pedestal store (which must be deleted) from OCDB for the given run static AliMUONVStore* CreatePedestals(Int_t runNumber, Int_t* startOfValidity=0); + /// Create a configuration store (which must be deleted) from OCDB for the given run + static AliMUONVStore* CreateConfig(Int_t runNumber, Int_t* startOfValidity=0); + /// Create a regional trigger mask store (which must be deleted) for a given run static AliMUONRegionalTriggerConfig* CreateRegionalTriggerConfig(Int_t runNumber, Int_t* startOfValidity=0); @@ -105,6 +108,9 @@ public: /// Get the pedestal store AliMUONVStore* Pedestals() const; + /// Get the config store + AliMUONVStore* Config() const; + /// Get the occupancy map store AliMUONVStore* OccupancyMap() const; @@ -166,8 +172,10 @@ private: static AliMUONVStore* fBypassPedestals; static AliMUONVStore* fBypassGains; - - ClassDef(AliMUONCalibrationData,12) // Storage for all MUON calibration data. + + mutable AliMUONVStore* fConfig; //!< configuration of the tracker + + ClassDef(AliMUONCalibrationData,13) // Storage for all MUON calibration data. }; #endif diff --git a/MUON/AliMUONGMSSubprocessor.cxx b/MUON/AliMUONGMSSubprocessor.cxx index 0ac04540f2c..d0d5e3bc65a 100644 --- a/MUON/AliMUONGMSSubprocessor.cxx +++ b/MUON/AliMUONGMSSubprocessor.cxx @@ -69,7 +69,7 @@ AliMUONGMSSubprocessor::~AliMUONGMSSubprocessor() //______________________________________________________________________________ -void AliMUONGMSSubprocessor::Initialize(Int_t /*run*/, +Bool_t AliMUONGMSSubprocessor::Initialize(Int_t /*run*/, UInt_t /*startTime*/, UInt_t /*endTime*/) { /// Instantiate geometry transformer @@ -78,6 +78,7 @@ void AliMUONGMSSubprocessor::Initialize(Int_t /*run*/, fTransformer = new AliMUONGeometryTransformer(); fTransformer->CreateModules(); } + return kTRUE; } //______________________________________________________________________________ diff --git a/MUON/AliMUONGMSSubprocessor.h b/MUON/AliMUONGMSSubprocessor.h index fcf544cbbd1..143c04858e0 100644 --- a/MUON/AliMUONGMSSubprocessor.h +++ b/MUON/AliMUONGMSSubprocessor.h @@ -29,7 +29,7 @@ class AliMUONGMSSubprocessor : public AliMUONVSubprocessor virtual ~AliMUONGMSSubprocessor(); // methods - virtual void Initialize(Int_t run, UInt_t startTime, UInt_t endTime); + virtual Bool_t Initialize(Int_t run, UInt_t startTime, UInt_t endTime); virtual UInt_t Process(TMap* /*dcsAliasMap*/); private: diff --git a/MUON/AliMUONGainSubprocessor.cxx b/MUON/AliMUONGainSubprocessor.cxx index bfdea997636..ed95018c53e 100644 --- a/MUON/AliMUONGainSubprocessor.cxx +++ b/MUON/AliMUONGainSubprocessor.cxx @@ -75,7 +75,7 @@ AliMUONGainSubprocessor::~AliMUONGainSubprocessor() } //_____________________________________________________________________________ -void +Bool_t AliMUONGainSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) { /// When starting a new run, reads in the Gains ASCII files. @@ -113,6 +113,8 @@ AliMUONGainSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) } } + delete sources; + if ( fSkip ) { delete fGains; @@ -124,9 +126,10 @@ AliMUONGainSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) Master()->Log("Failed to read any Gains"); delete fGains; fGains = 0x0; + return kFALSE; } - delete sources; + return kTRUE; } //_____________________________________________________________________________ diff --git a/MUON/AliMUONGainSubprocessor.h b/MUON/AliMUONGainSubprocessor.h index b144fdea53d..d6bb61ae270 100644 --- a/MUON/AliMUONGainSubprocessor.h +++ b/MUON/AliMUONGainSubprocessor.h @@ -29,7 +29,7 @@ public: AliMUONGainSubprocessor(AliMUONPreprocessor* master); virtual ~AliMUONGainSubprocessor(); - void Initialize(Int_t run, UInt_t startTime, UInt_t endTime); + Bool_t Initialize(Int_t run, UInt_t startTime, UInt_t endTime); UInt_t Process(TMap* dcsAliasMap); private: diff --git a/MUON/AliMUONMchViewApplication.cxx b/MUON/AliMUONMchViewApplication.cxx index e7678a091f4..fdf57a7ffb8 100644 --- a/MUON/AliMUONMchViewApplication.cxx +++ b/MUON/AliMUONMchViewApplication.cxx @@ -414,14 +414,18 @@ AliMUONMchViewApplication::ReleaseNotes() TGTextView* rn = new TGTextView(t); + rn->AddLine("1.01"); + rn->AddLine(""); + rn->AddLine("Added the configuration as a possible OCDB data source"); + rn->AddLine(""); + rn->AddLine("1.00"); rn->AddLine(""); rn->AddLine("Added the Status and StatusMap as a possible OCDB data source"); rn->AddLine(""); rn->AddLine("Added one (computed) dimension to the Gains data source = 1/a1/0.2 (mV/fC)"); rn->AddLine(""); - - + rn->AddLine("0.99a"); rn->AddLine(""); rn->AddLine("Added the --de and --chamber options"); diff --git a/MUON/AliMUONMchViewApplication.h b/MUON/AliMUONMchViewApplication.h index 937653971f1..8b1260a6136 100644 --- a/MUON/AliMUONMchViewApplication.h +++ b/MUON/AliMUONMchViewApplication.h @@ -30,7 +30,7 @@ public: void HandleMenu(Int_t i); /// Return the version number of the mchview application - static const char* Version() { return "1.00"; } + static const char* Version() { return "1.01"; } /// Return the SVN revision and version number of the mchview application static const char* FullVersion() { return Form("mchview Version %s ($Id$)",Version()); } diff --git a/MUON/AliMUONOccupancySubprocessor.cxx b/MUON/AliMUONOccupancySubprocessor.cxx index 5ff5afbb60a..cd4bc3a1d1f 100644 --- a/MUON/AliMUONOccupancySubprocessor.cxx +++ b/MUON/AliMUONOccupancySubprocessor.cxx @@ -58,7 +58,7 @@ AliMUONOccupancySubprocessor::~AliMUONOccupancySubprocessor() } //_____________________________________________________________________________ -void +Bool_t AliMUONOccupancySubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) { /// When starting a new run, reads in the occupancy ASCII files. @@ -87,13 +87,16 @@ AliMUONOccupancySubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t end } } + delete sources; + if (!n) { Master()->Log("Failed to read any occupancy"); delete fOccupancyMap; fOccupancyMap = 0; + return kFALSE; } - delete sources; + return kTRUE; } //_____________________________________________________________________________ diff --git a/MUON/AliMUONOccupancySubprocessor.h b/MUON/AliMUONOccupancySubprocessor.h index c58276dd765..6e107fe5595 100644 --- a/MUON/AliMUONOccupancySubprocessor.h +++ b/MUON/AliMUONOccupancySubprocessor.h @@ -24,7 +24,7 @@ public: AliMUONOccupancySubprocessor(AliMUONPreprocessor* master); virtual ~AliMUONOccupancySubprocessor(); - void Initialize(Int_t run, UInt_t startTime, UInt_t endTime); + Bool_t Initialize(Int_t run, UInt_t startTime, UInt_t endTime); UInt_t Process(TMap* dcsAliasMap); void Print(Option_t* opt="") const; diff --git a/MUON/AliMUONPainterDataSourceFrame.cxx b/MUON/AliMUONPainterDataSourceFrame.cxx index e5e306d7dc4..d48913bf339 100644 --- a/MUON/AliMUONPainterDataSourceFrame.cxx +++ b/MUON/AliMUONPainterDataSourceFrame.cxx @@ -181,6 +181,7 @@ AliMUONPainterDataSourceFrame::AliMUONPainterDataSourceFrame(const TGWindow* p, fOCDBTypes->AddEntry("Occupancy",4); fOCDBTypes->AddEntry("StatusMap",5); fOCDBTypes->AddEntry("Status",6); + fOCDBTypes->AddEntry("Config",7); fOCDBTypes->Select(0); fOCDBTypes->Resize(100,20); diff --git a/MUON/AliMUONPedestalEventGenerator.cxx b/MUON/AliMUONPedestalEventGenerator.cxx index b07d17ee912..c3e2d73ab55 100644 --- a/MUON/AliMUONPedestalEventGenerator.cxx +++ b/MUON/AliMUONPedestalEventGenerator.cxx @@ -152,7 +152,7 @@ AliMUONPedestalEventGenerator::ConvertRawFilesToDate() const Int_t kIDet = AliDAQ::DetectorID("MUONTRK"); - const Int_t kNLDCs = TMath::CeilNint(AliDAQ::NumberOfLdcs(kIDet)); + const Int_t kNLDCs = 5;//TMath::CeilNint(AliDAQ::NumberOfLdcs(kIDet)); char* path = gSystem->Which(gSystem->Getenv("PATH"), "dateStream"); if (!path) @@ -174,7 +174,7 @@ AliMUONPedestalEventGenerator::ConvertRawFilesToDate() char command[256]; // Note the option -s. It is used in order to avoid // the generation of SOR/EOR events. - sprintf(command, "dateStream -s -D -o %s.LDC%d -# %d -C", + sprintf(command, "dateStream -c -D -o %s.LDC%d -# %d -C", fDateFileName.Data(), iFile, runLoader->GetNumberOfEvents()); pipe[iFile] = gSystem->OpenPipe(command, "w"); } diff --git a/MUON/AliMUONPedestalSubprocessor.cxx b/MUON/AliMUONPedestalSubprocessor.cxx index ccc7a545268..056168890f5 100644 --- a/MUON/AliMUONPedestalSubprocessor.cxx +++ b/MUON/AliMUONPedestalSubprocessor.cxx @@ -55,7 +55,9 @@ AliMUONPedestalSubprocessor::AliMUONPedestalSubprocessor(AliMUONPreprocessor* ma : AliMUONVSubprocessor(master, "Pedestals", "Upload MUON Tracker pedestals to OCDB"), -fPedestals(0x0) +fPedestals(0x0), +fConfig(0x0), +fConfigChanged(kFALSE) { /// default ctor } @@ -65,10 +67,11 @@ AliMUONPedestalSubprocessor::~AliMUONPedestalSubprocessor() { /// dtor delete fPedestals; + delete fConfig; } //_____________________________________________________________________________ -void +Bool_t AliMUONPedestalSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) { /// When starting a new run, reads in the pedestals ASCII files. @@ -79,6 +82,9 @@ AliMUONPedestalSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endT delete fPedestals; fPedestals = new AliMUON2DMap(kTRUE); + delete fConfig; + fConfig = new AliMUON2DMap(kTRUE); + Master()->Log(Form("Reading pedestal files for Run %d startTime %ld endTime %ld", run,startTime,endTime)); @@ -86,24 +92,64 @@ AliMUONPedestalSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endT TIter next(sources); TObjString* o(0x0); Int_t n(0); + Int_t npedFiles(0); while ( ( o = static_cast(next()) ) ) { TString fileName(Master()->GetFile(kSystem,kId,o->GetName())); - Int_t ok = ReadFile(fileName.Data()); + Int_t ok = ReadPedestalFile(fileName.Data()); if (ok>0) { n += ok; + ++npedFiles; } } + + delete sources; if (!n) { Master()->Log("Failed to read any pedestals"); delete fPedestals; fPedestals = 0; + delete fConfig; + fConfig = 0; + return kFALSE; + } + + const char* kIdConf = "CONFIG"; + + sources = Master()->GetFileSources(kSystem,kIdConf); + TIter nextConf(sources); + Int_t nconf(0); + Int_t nconfFiles(0); + + fConfigChanged = kFALSE; + + while ( ( o = static_cast(nextConf()) ) ) + { + TString fileName(Master()->GetFile(kSystem,kIdConf,o->GetName())); + Int_t ok = ReadConfigFile(fileName.Data()); + if (ok>0) + { + nconf += ok; + ++nconfFiles; + } } + delete sources; + + if ( npedFiles != nconfFiles ) + { + Master()->Log(Form("ERROR : Number of config files (%d) different from number of pedestal files (%d)",nconfFiles,npedFiles)); + delete fPedestals; + fPedestals = 0; + delete fConfig; + fConfig = 0; + return kFALSE; + } + + return kTRUE; } //_____________________________________________________________________________ @@ -112,9 +158,9 @@ AliMUONPedestalSubprocessor::Process(TMap* /*dcsAliasMap*/) { /// Store the pedestals into the CDB - if (!fPedestals) + if (!fPedestals || !fConfig) { - // this is the only reason to fail for the moment : getting no pedestal + // this is the only reason to fail for the moment : getting no pedestal or no config // at all. return 1; } @@ -123,7 +169,7 @@ AliMUONPedestalSubprocessor::Process(TMap* /*dcsAliasMap*/) Master()->Log("Validating"); - TObjArray* chambers = validator.Validate(*fPedestals); + TObjArray* chambers = validator.Validate(*fPedestals,fConfig); if (chambers) { @@ -143,7 +189,11 @@ AliMUONPedestalSubprocessor::Process(TMap* /*dcsAliasMap*/) } } - Master()->Log("Storing pedestals"); + Master()->Log("Storing pedestals..."); + if ( fConfigChanged ) + { + Master()->Log("...and configuration, as it has changed"); + } AliCDBMetaData metaData; metaData.SetBeamPeriod(0); @@ -154,13 +204,16 @@ AliMUONPedestalSubprocessor::Process(TMap* /*dcsAliasMap*/) Bool_t validToInfinity = kTRUE; Bool_t result = Master()->Store("Calib", "Pedestals", fPedestals, &metaData, 0, validToInfinity); - + if ( fConfigChanged ) + { + result = result && Master()->Store("Calib", "Config", fConfig, &metaData, 0, validToInfinity); + } return ( result != kTRUE ); // return 0 if everything is ok. } //_____________________________________________________________________________ Int_t -AliMUONPedestalSubprocessor::ReadFile(const char* filename) +AliMUONPedestalSubprocessor::ReadPedestalFile(const char* filename) { /// Read the pedestals from an ASCII file. \n /// Format of that file is one line per channel : \n @@ -187,6 +240,34 @@ AliMUONPedestalSubprocessor::ReadFile(const char* filename) return n; } +//_____________________________________________________________________________ +Int_t +AliMUONPedestalSubprocessor::ReadConfigFile(const char* filename) +{ + /// Read the configuration from an ASCII file. + /// Format of that file is one line per manu : + /// BUS_PATCH MANU_ADDR + /// And the first line contains "unchanged" if the configuration is the same + /// as before. + /// Return kFALSE if reading was not successfull. + /// + + TString sFilename(gSystem->ExpandPathName(filename)); + + Master()->Log(Form("Reading %s",sFilename.Data())); + + Int_t n = AliMUONTrackerIO::ReadConfig(sFilename.Data(),*fConfig,fConfigChanged); + + switch (n) + { + case -1: + Master()->Log(Form("Could not open %s",sFilename.Data())); + break; + } + + return n; +} + //_____________________________________________________________________________ void @@ -194,4 +275,6 @@ AliMUONPedestalSubprocessor::Print(Option_t* opt) const { /// ouput to screen if (fPedestals) fPedestals->Print("",opt); + if (fConfig) fConfig->Print("",opt); } + diff --git a/MUON/AliMUONPedestalSubprocessor.h b/MUON/AliMUONPedestalSubprocessor.h index 699d341804c..cc231eb5d7c 100644 --- a/MUON/AliMUONPedestalSubprocessor.h +++ b/MUON/AliMUONPedestalSubprocessor.h @@ -25,7 +25,7 @@ public: AliMUONPedestalSubprocessor(AliMUONPreprocessor* master); virtual ~AliMUONPedestalSubprocessor(); - void Initialize(Int_t run, UInt_t startTime, UInt_t endTime); + Bool_t Initialize(Int_t run, UInt_t startTime, UInt_t endTime); UInt_t Process(TMap* dcsAliasMap); void Print(Option_t* opt="") const; @@ -35,12 +35,15 @@ private: /// Not implemented AliMUONPedestalSubprocessor& operator=(const AliMUONPedestalSubprocessor&); - Int_t ReadFile(const char* filename); + Int_t ReadPedestalFile(const char* filename); + Int_t ReadConfigFile(const char* filename); private: AliMUONVStore* fPedestals; //!< Pedestals for the MUON TRK + AliMUONVStore* fConfig; //!< Configuration (i.e. list of (buspatch,manu)) for the MUON TRK + Bool_t fConfigChanged; //!< flag to trigger the saving of the configuration - ClassDef(AliMUONPedestalSubprocessor,1) // A shuttle preprocessor for MUON TRK pedestals + ClassDef(AliMUONPedestalSubprocessor,2) // A shuttle preprocessor for MUON TRK pedestals }; #endif diff --git a/MUON/AliMUONPreprocessor.cxx b/MUON/AliMUONPreprocessor.cxx index 2488db2a5e9..9265a1cc873 100644 --- a/MUON/AliMUONPreprocessor.cxx +++ b/MUON/AliMUONPreprocessor.cxx @@ -120,13 +120,17 @@ AliMUONPreprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) } } + Int_t nok(0); + if (IsValid()) { // loop over subtasks and initialize them for ( Int_t i = 0; i <= fSubprocessors->GetLast(); ++i ) { - Subprocessor(i)->Initialize(run,startTime,endTime); + Bool_t ok = Subprocessor(i)->Initialize(run,startTime,endTime); + if (ok) ++nok; } + if (nok != fSubprocessors->GetLast()+1) fIsValid = kFALSE; } Log(Form("Initialize was %s",( IsValid() ? "fine" : "NOT OK"))); } diff --git a/MUON/AliMUONPreprocessor.h b/MUON/AliMUONPreprocessor.h index 1d3247eef05..95e33b93ff9 100644 --- a/MUON/AliMUONPreprocessor.h +++ b/MUON/AliMUONPreprocessor.h @@ -65,6 +65,9 @@ public: /// Whether we should do something or not Bool_t IsApplicable() { return fIsApplicable; } + TString GetLogBookParam(const char* parname) + { return TString(AliPreprocessor::GetRunParameter(parname)); } + protected: AliMUONPreprocessor(const char* detName, AliShuttleInterface* shuttle); virtual ~AliMUONPreprocessor(); diff --git a/MUON/AliMUONTrackerIO.cxx b/MUON/AliMUONTrackerIO.cxx index 6e766d9fa97..c14047ad843 100644 --- a/MUON/AliMUONTrackerIO.cxx +++ b/MUON/AliMUONTrackerIO.cxx @@ -30,12 +30,14 @@ ClassImp(AliMUONTrackerIO) /// \endcond +#include "AliDCSValue.h" #include "AliLog.h" #include "AliMUONCalibParamND.h" #include "AliMUONCalibParamNF.h" #include "AliMUONVStore.h" #include "AliMpConstants.h" #include "AliMpDDLStore.h" +#include "AliMpDEManager.h" #include "AliMpDetElement.h" #include #include @@ -205,6 +207,14 @@ AliMUONTrackerIO::DecodePedestals(TString data, AliMUONVStore& pedStore) std::istringstream sin(line); sin >> busPatchID >> manuID >> manuChannel >> pedMean >> pedSigma; Int_t detElemID = AliMpDDLStore::Instance()->GetDEfromBus(busPatchID); + + if ( !AliMpDEManager::IsValidDetElemId(detElemID) ) + { + AliErrorClass(Form("Got an invalid DE = %d from busPatchId=%d manuId=%d", + detElemID,busPatchID,manuID)); + continue; + } + AliDebugClass(3,Form("BUSPATCH %3d DETELEMID %4d MANU %3d CH %3d MEAN %7.2f SIGMA %7.2f", busPatchID,detElemID,manuID,manuChannel,pedMean,pedSigma)); @@ -343,6 +353,14 @@ AliMUONTrackerIO::DecodeGains(TString data, AliMUONVStore& gainStore, &a0,&a1,&thres,&qual); AliDebugClass(3,Form("line=%s",line)); Int_t detElemID = AliMpDDLStore::Instance()->GetDEfromBus(busPatchID); + + if ( !AliMpDEManager::IsValidDetElemId(detElemID) ) + { + AliErrorClass(Form("Got an invalid DE = %d from busPatchId=%d manuId=%d", + detElemID,busPatchID,manuID)); + continue; + } + AliDebugClass(3,Form("BUSPATCH %3d DETELEMID %4d MANU %3d CH %3d A0 %7.2f " "A1 %e THRES %5d QUAL %x", busPatchID,detElemID,manuID,manuChannel,a0,a1,thres,qual)); @@ -433,3 +451,118 @@ AliMUONTrackerIO::ReadCapacitances(const char* file, AliMUONVStore& capaStore) return ngenerated; } + +//_____________________________________________________________________________ +Int_t +AliMUONTrackerIO::ReadConfig(const char* filename, AliMUONVStore& confStore, Bool_t& changed) +{ + /// Read config file (produced by the MUONTRKda.exe program for instance) + /// and append the read values into the given VStore + /// To be used when the input is a file (for instance when reading data + /// from the OCDB). + /// changed must be set to kFALSE before calling this method for the first time + /// (then the subsequent calls must not set it !) + /// + + TString sFilename(gSystem->ExpandPathName(filename)); + + std::ifstream in(sFilename.Data()); + if (!in.good()) + { + return kCannotOpenFile; + } + + TString datastring; + ostringstream stream; + char line[1024]; + while ( in.getline(line,1024) ) + stream << line << "\n"; + datastring = TString(stream.str().c_str()); + + in.close(); + + return DecodeConfig(datastring,confStore,changed); +} + +//_____________________________________________________________________________ +Int_t +AliMUONTrackerIO::DecodeConfig(TString data, AliMUONVStore& confStore, Bool_t& changed) +{ + /// Read config data (produced by the MUONTRKda.exe program for instance) + /// and append the read values into the given VStore + /// To be used when the input is a TString (for instance when getting data + /// from AMORE DB). + /// changed must be set to kFALSE before calling this method for the first time + /// (then the subsequent calls must not set it !) + + char line[1024]; + Int_t busPatchID, manuID; + Int_t n(0); + istringstream in(data.Data()); + + while ( in.getline(line,1024) ) + { + AliDebugClass(3,Form("line=%s",line)); + if ( line[0] == '#' ) + { + TString sline(line); + sline.ToUpper(); + if (sline.Contains("CHANGED") && !sline.Contains("UNCHANGED")) changed = kTRUE; + continue; + } + std::istringstream sin(line); + sin >> busPatchID >> manuID; + + Int_t detElemID = AliMpDDLStore::Instance()->GetDEfromBus(busPatchID); + + if ( !AliMpDEManager::IsValidDetElemId(detElemID) ) + { + AliErrorClass(Form("Got an invalid DE = %d from busPatchId=%d manuId=%d", + detElemID,busPatchID,manuID)); + continue; + } + + AliMUONVCalibParam* conf = + static_cast(confStore.FindObject(detElemID,manuID)); + if (!conf) + { + conf = new AliMUONCalibParamNF(1,1,detElemID,manuID,1); + confStore.Add(conf); + } + ++n; + } + + return n; +} + +//_____________________________________________________________________________ +Int_t +AliMUONTrackerIO::WriteConfig(ofstream& out, AliMUONVStore& confStore) +{ + /// Write the conf store as an ASCII file + /// Note that we are converting (back) the detElemId into a busPatchId + /// Return the number of lines written + + if ( !AliMpDDLStore::Instance() ) + { + cout << "ERROR: mapping not loaded. Cannot work" << endl; + return 0; + } + + TIter next(confStore.CreateIterator()); + AliMUONVCalibParam* param; + Int_t n(0); + + while ( (param=static_cast(next())) ) + { + Int_t detElemId = param->ID0(); + Int_t manuId = param->ID1(); + + Int_t busPatchId = AliMpDDLStore::Instance()->GetBusPatchId(detElemId,manuId); + ++n; + + out << busPatchId << " " << manuId << endl; + } + return n; +} + diff --git a/MUON/AliMUONTrackerIO.h b/MUON/AliMUONTrackerIO.h index 510b7ca1f66..ee61b0d9342 100644 --- a/MUON/AliMUONTrackerIO.h +++ b/MUON/AliMUONTrackerIO.h @@ -25,6 +25,10 @@ public: AliMUONTrackerIO(); virtual ~AliMUONTrackerIO(); + static Int_t ReadConfig(const char* filename, AliMUONVStore& confStore, Bool_t& changed); + static Int_t DecodeConfig(TString data, AliMUONVStore& confStore, Bool_t& changed); + static Int_t WriteConfig(ofstream& out, AliMUONVStore& confStore); + static Int_t ReadPedestals(const char* filename, AliMUONVStore& pedStore); static Int_t DecodePedestals(TString data, AliMUONVStore& pedStore); diff --git a/MUON/AliMUONTrackerOCDBDataMaker.cxx b/MUON/AliMUONTrackerOCDBDataMaker.cxx index a93e4cfd4ac..a4432609b1f 100644 --- a/MUON/AliMUONTrackerOCDBDataMaker.cxx +++ b/MUON/AliMUONTrackerOCDBDataMaker.cxx @@ -78,6 +78,13 @@ AliMUONTrackerOCDBDataMaker::AliMUONTrackerOCDBDataMaker(const char* ocdbPath, store = AliMUONCalibrationData::CreatePedestals(runNumber,&startOfValidity); fData = CreateDataPedestals(startOfValidity); } + else if ( stype == "CONFIG" ) + { + store = AliMUONCalibrationData::CreateConfig(runNumber,&startOfValidity); + fData = new AliMUONTrackerData(Form("CONFIG%d",startOfValidity),"Configuration",1); + fData->SetDimensionName(0,"there"); + fData->DisableChannelLevel(); + } else if ( stype == "OCCUPANCY" ) { store = AliMUONCalibrationData::CreateOccupancyMap(runNumber,&startOfValidity); diff --git a/MUON/AliMUONTriggerSubprocessor.cxx b/MUON/AliMUONTriggerSubprocessor.cxx index 57b90404962..bea01143d26 100644 --- a/MUON/AliMUONTriggerSubprocessor.cxx +++ b/MUON/AliMUONTriggerSubprocessor.cxx @@ -84,7 +84,7 @@ AliMUONTriggerSubprocessor::GetFileName(const char* fid) const } //_____________________________________________________________________________ -void +Bool_t AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime) { /// When starting a new run, reads in the trigger online files. @@ -114,7 +114,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi { Master()->Log("FATAL ERROR : DA does not seem to have been run !!!"); Master()->Invalidate(); - return; + return kFALSE; } // OK. We have an exportedFiles.dat file at hand. @@ -130,7 +130,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi if ((globalFile+regionalFile+localFile+lutFile) == 0) { Master()->Log("No file(s) to be processed for this run. Exiting."); - return; + return kTRUE; } delete fRegionalConfig; fRegionalConfig = 0x0; @@ -151,7 +151,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi { Master()->Log("Could not read some input file(s). Aborting"); Master()->Invalidate(); - return; + return kFALSE; } if ( regionalFile ) fRegionalConfig = new AliMUONRegionalTriggerConfig(); @@ -192,6 +192,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi fLUT = 0x0; } } + return kTRUE; } //_____________________________________________________________________________ diff --git a/MUON/AliMUONTriggerSubprocessor.h b/MUON/AliMUONTriggerSubprocessor.h index 5a12de2c29d..8450f2be746 100644 --- a/MUON/AliMUONTriggerSubprocessor.h +++ b/MUON/AliMUONTriggerSubprocessor.h @@ -29,7 +29,7 @@ public: AliMUONTriggerSubprocessor(AliMUONPreprocessor* master); virtual ~AliMUONTriggerSubprocessor(); - void Initialize(Int_t run, UInt_t startTime, UInt_t endTime); + Bool_t Initialize(Int_t run, UInt_t startTime, UInt_t endTime); UInt_t Process(TMap* dcsAliasMap); private: diff --git a/MUON/AliMUONVSubprocessor.cxx b/MUON/AliMUONVSubprocessor.cxx index 9391585ff5f..8cf3c40d53d 100644 --- a/MUON/AliMUONVSubprocessor.cxx +++ b/MUON/AliMUONVSubprocessor.cxx @@ -52,14 +52,15 @@ AliMUONVSubprocessor::~AliMUONVSubprocessor() } //_____________________________________________________________________________ -void +Bool_t AliMUONVSubprocessor::Initialize(Int_t /*run*/, UInt_t startTime, UInt_t endTime) { /// optional - fStartTime = startTime; - fEndTime = endTime; + fStartTime = startTime; // time_created + fEndTime = endTime; // time_completed + return kTRUE; } //_____________________________________________________________________________ diff --git a/MUON/AliMUONVSubprocessor.h b/MUON/AliMUONVSubprocessor.h index 094bc74253b..fb61f426428 100644 --- a/MUON/AliMUONVSubprocessor.h +++ b/MUON/AliMUONVSubprocessor.h @@ -27,7 +27,7 @@ public: const char* name="", const char* title=""); virtual ~AliMUONVSubprocessor(); - virtual void Initialize(Int_t run, UInt_t startTime, UInt_t endTime); + virtual Bool_t Initialize(Int_t run, UInt_t startTime, UInt_t endTime); /// Process this sub-task virtual UInt_t Process(TMap* dcsAliasMap) = 0; diff --git a/MUON/TestMUONPreprocessor.C b/MUON/TestMUONPreprocessor.C index 682398304e3..be2de3132a2 100644 --- a/MUON/TestMUONPreprocessor.C +++ b/MUON/TestMUONPreprocessor.C @@ -29,8 +29,10 @@ /// the rootlogon.C there) before compiling this macro : ///
 /// gSystem->Load("$ALICE_ROOT/SHUTTLE/TestShuttle/libTestShuttle");
-/// gSystem->Load("$ALICE_ROOT/MUON/libMUONshuttle");
+/// gSystem->Load("libMUONshuttle");
 /// 
+/// Last line above assume you have $ALICE_ROOT/MUON/lib/tgt_[arch] (where +/// libMUONshuttle is located) in your LD_LIBRARY_PATH /// /// Having $ALICE_ROOT/SHUTTLE/TestShuttle directory in your LD_LIBRARY_PATH /// (or DYLD_LIBRARY_PATH on Mac OS X) won't hurt either... @@ -75,6 +77,13 @@ /// LDC1.ped /// LDC2.ped /// LDC3.ped +/// LDC4.conf +/// CONFIG/ +/// LDC0.conf +/// LDC1.conf +/// LDC2.conf +/// LDC3.conf +/// LDC4.conf /// TRIGGER/ /// ExportedFiles.dat (mandatory) /// MtgGlobalCrate-1.dat @@ -105,8 +114,10 @@ #include "AliLog.h" +#include "AliMpBusPatch.h" #include "AliMpExMap.h" #include "AliMpHelper.h" +#include "AliMpDDLStore.h" #include "AliMpDCSNamer.h" #include "AliMpCDB.h" @@ -126,6 +137,7 @@ #include "TRandom.h" #endif +//______________________________________________________________________________ void TestMUONPreprocessor(Int_t runNumber=80, const char* runType="CALIBRATION", const char* sourceDirectory="/afs/cern.ch/user/l/laphecet/public") @@ -139,6 +151,9 @@ void TestMUONPreprocessor(Int_t runNumber=80, // create AliTestShuttle instance // The parameters are run, startTime, endTime + + gSystem->Load("libTestShuttle.so"); + AliTestShuttle* shuttle = new AliTestShuttle(runNumber, 0, 1); const char* inputCDB = "local://$ALICE_ROOT/OCDB/SHUTTLE/TestShuttle/TestCDB"; @@ -153,6 +168,8 @@ void TestMUONPreprocessor(Int_t runNumber=80, if ( rt.Contains("PHYSICS") ) { // Create DCS aliases + UInt_t startTime, endTime; + TMap* dcsAliasMap = CreateDCSAliasMap(inputCDB, runNumber); if ( dcsAliasMap ) @@ -181,7 +198,14 @@ void TestMUONPreprocessor(Int_t runNumber=80, shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","PEDESTALS","LDC1",Form("%s/PEDESTALS/LDC1.ped",sourceDirectory)); shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","PEDESTALS","LDC2",Form("%s/PEDESTALS/LDC2.ped",sourceDirectory)); shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","PEDESTALS","LDC3",Form("%s/PEDESTALS/LDC3.ped",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","PEDESTALS","LDC4",Form("%s/PEDESTALS/LDC4.ped",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","CONFIG","LDC0",Form("%s/CONFIG/LDC0.conf",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","CONFIG","LDC1",Form("%s/CONFIG/LDC1.conf",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","CONFIG","LDC2",Form("%s/CONFIG/LDC2.conf",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","CONFIG","LDC3",Form("%s/CONFIG/LDC3.conf",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","CONFIG","LDC4",Form("%s/CONFIG/LDC4.conf",sourceDirectory)); + shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","GAINS","LDC0",Form("%s/GAINS/LDC0.gain",sourceDirectory)); shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","GAINS","LDC1",Form("%s/GAINS/LDC1.gain",sourceDirectory)); shuttle->AddInputFile(AliTestShuttle::kDAQ,"MCH","GAINS","LDC2",Form("%s/GAINS/LDC2.gain",sourceDirectory)); @@ -215,6 +239,70 @@ void TestMUONPreprocessor(Int_t runNumber=80, shuttle->Process(); } +//______________________________________________________________________________ +void GenerateConfig() +{ + /// Generate "fake" configuration files for the tracker. One per LDC. + + Bool_t undefStorage(kFALSE); + + AliCDBManager* man = AliCDBManager::Instance(); + if (!man->IsDefaultStorageSet()) + { + undefStorage = kTRUE; + man->SetDefaultStorage("local://$ALICE_ROOT/OCDB"); + man->SetRun(0); + } + + // Load mapping + Bool_t ok = AliMpCDB::LoadDDLStore(); + + if (undefStorage) + { + man->UnsetDefaultStorage(); + } + + if (!ok) + { + AliErrorGeneral("GenerateConfig","Could not load DDLStore from OCDB"); + return; + } + + ofstream* files[5]; + for ( Int_t i = 0; i < 5; ++i ) + { + files[i]=0; + } + + TIter next(AliMpDDLStore::Instance()->CreateBusPatchIterator()); + AliMpBusPatch* bp; + + while ( ( bp = static_cast(next()) ) ) + { + Int_t ddl = bp->GetDdlId(); + + Int_t ldc = ddl/4; + + if (!files[ldc]) + { + files[ldc] = new ofstream(Form("LDC%d.conf",ldc)); + *(files[ldc]) << "# changed" << endl; + } + + for ( Int_t imanu = 0; imanu < bp->GetNofManus(); ++imanu ) + { + *(files[ldc]) << bp->GetId() << " " << bp->GetManuId(imanu) << endl; + } + } + + for ( Int_t i = 0; i < 5; ++i ) + { + if ( files[i] ) files[i]->close(); + delete files[i]; + } +} + +//______________________________________________________________________________ TMap* CreateDCSAliasMap(const char* inputCDB, Int_t runNumber) { /// Creates a DCS structure for MUON Tracker HV and Trigger DCS and Currents @@ -272,54 +360,52 @@ TMap* CreateDCSAliasMap(const char* inputCDB, Int_t runNumber) TString& aliasName = alias->String(); if ( aliasName.Contains("sw") && sDetName.Contains("TRACKER")) { - // HV Switch (St345 only) - TObjArray* valueSet = new TObjArray; - valueSet->SetOwner(kTRUE); - Bool_t bvalue = kTRUE; -// Float_t r = random.Uniform(); -// if ( r < 0.007 ) value = kFALSE; -// if ( aliasName.Contains("DE513sw2") ) value = kFALSE; - - for ( UInt_t timeStamp = 0; timeStamp < 60*3; timeStamp += 60 ) - { - AliDCSValue* dcsValue = new AliDCSValue(bvalue,timeStamp); - valueSet->Add(dcsValue); - } - aliasMap->Add(new TObjString(*alias),valueSet); + // HV Switch (St345 only) + TObjArray* valueSet = new TObjArray; + valueSet->SetOwner(kTRUE); + Bool_t bvalue = kTRUE; + // Float_t r = random.Uniform(); + // if ( r < 0.007 ) value = kFALSE; + // if ( aliasName.Contains("DE513sw2") ) value = kFALSE; + + for ( UInt_t timeStamp = 0; timeStamp < 60*3; timeStamp += 60 ) + { + AliDCSValue* dcsValue = new AliDCSValue(bvalue,timeStamp); + valueSet->Add(dcsValue); + } + aliasMap->Add(new TObjString(*alias),valueSet); } else { - TObjArray* valueSet = new TObjArray; - valueSet->SetOwner(kTRUE); - for ( UInt_t timeStamp = 0; timeStamp < 60*15; timeStamp += 120 ) - { - Float_t value = 0; - if(sDetName.Contains("TRACKER")){ - value = random.Gaus(1750,62.5); - if ( aliasName == "MchHvLvLeft/Chamber00Left/Quad2Sect1.actual.vMon") value = 500; - } - else if(aliasName.Contains("iMon")){ - value = random.Gaus(2.,0.4); - } - else { - value = random.Gaus(8000.,16.); - } - - AliDCSValue* dcsValue = new AliDCSValue(value,timeStamp); - valueSet->Add(dcsValue); - } - if ( aliasName == "MchHvLvLeft/Chamber04Left/Slat06.actual.vMon" ) continue; - if ( aliasName == "MTR_INSIDE_MT22_RPC3_HV.vEff" ) continue; - if ( aliasName == "MTR_OUTSIDE_MT21_RPC4_HV.actual.iMon" ) continue; - aliasMap->Add(new TObjString(*alias),valueSet); + TObjArray* valueSet = new TObjArray; + valueSet->SetOwner(kTRUE); + for ( UInt_t timeStamp = 0; timeStamp < 60*15; timeStamp += 120 ) + { + Float_t value = 0; + if(sDetName.Contains("TRACKER")){ + value = random.Gaus(1750,62.5); + if ( aliasName == "MchHvLvLeft/Chamber00Left/Quad2Sect1.actual.vMon") value = 500; + } + else if(aliasName.Contains("iMon")){ + value = random.Gaus(2.,0.4); + } + else { + value = random.Gaus(8000.,16.); + } + + AliDCSValue* dcsValue = new AliDCSValue(value,timeStamp); + valueSet->Add(dcsValue); + } + if ( aliasName == "MchHvLvLeft/Chamber04Left/Slat06.actual.vMon" ) continue; + if ( aliasName == "MTR_INSIDE_MT22_RPC3_HV.vEff" ) continue; + if ( aliasName == "MTR_OUTSIDE_MT21_RPC4_HV.actual.iMon" ) continue; + aliasMap->Add(new TObjString(*alias),valueSet); } } // loop on aliases - + delete aliases; } // loop on detectors (tracker and trigger) - - AliMpCDB::UnloadAll(); return aliasMap; -- 2.43.0