1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
19 Responsible: Raphaelle Bailhache (rbailhache@ikf.uni-frankfurt.de)
20 Code to analyze the TRD calibration and to produce OCDB entries
24 gSystem->Load("libANALYSIS");
25 gSystem->Load("libTRDcalib");
27 AliTRDPreprocessorOffline proces;
28 TString ocdbPath="local:////"
29 ocdbPath+=gSystem->GetFromPipe("pwd");
31 proces.CalibTimeGain("CalibObjects.root",run0,run1,ocdbPath);
32 proces.CalibTimeVdrift("CalibObjects.root",run0,run1,ocdbPath);
33 // take the raw calibration data from the file CalibObjects.root
34 // and make a OCDB entry with run validity run0-run1
35 // results are stored at the ocdbPath - local or alien ...
36 // default storage ""- data stored at current working directory
39 #include "Riostream.h"
48 #include "TProfile2D.h"
49 #include "AliTRDCalDet.h"
50 #include "AliTRDCalPad.h"
51 #include "AliCDBMetaData.h"
53 #include "AliCDBManager.h"
54 #include "AliCDBStorage.h"
55 #include "AliTRDCalibraMode.h"
56 #include "AliTRDCalibraFit.h"
57 #include "AliTRDCalibraVdriftLinearFit.h"
58 #include "AliTRDPreprocessorOffline.h"
61 ClassImp(AliTRDPreprocessorOffline)
63 AliTRDPreprocessorOffline::AliTRDPreprocessorOffline():
64 TNamed("TPCPreprocessorOffline","TPCPreprocessorOffline"),
66 fNameList("TRDCalib"),
68 fCalDetVdriftUsed(0x0),
72 fAliTRDCalibraVdriftLinearFit(0x0),
75 fPlots(new TObjArray(8)),
76 fCalibObjects(new TObjArray(8)),
78 fSubVersionGainUsed(0),
79 fVersionVdriftUsed(0),
80 fSubVersionVdriftUsed(0)
83 // default constructor
87 AliTRDPreprocessorOffline::~AliTRDPreprocessorOffline() {
92 if(fCalDetGainUsed) delete fCalDetGainUsed;
93 if(fCalDetVdriftUsed) delete fCalDetVdriftUsed;
94 if(fCH2d) delete fCH2d;
95 if(fPH2d) delete fPH2d;
96 if(fPRF2d) delete fPRF2d;
97 if(fAliTRDCalibraVdriftLinearFit) delete fAliTRDCalibraVdriftLinearFit;
98 if(fNEvents) delete fNEvents;
99 if(fAbsoluteGain) delete fAbsoluteGain;
100 if(fPlots) delete fPlots;
101 if(fCalibObjects) delete fCalibObjects;
105 void AliTRDPreprocessorOffline::CalibVdriftT0(const Char_t* file, Int_t startRunNumber, Int_t endRunNumber, TString ocdbStorage){
107 // make calibration of the drift velocity
109 // file - the location of input file
110 // startRunNumber, endRunNumber - run validity period
111 // ocdbStorage - path to the OCDB storage
112 // - if empty - local storage 'pwd' uesed
113 if (ocdbStorage.Length()<=0) ocdbStorage="local://"+gSystem->GetFromPipe("pwd")+"/OCDB";
118 // 2. extraction of the information
120 if(ReadVdriftT0Global(file)) AnalyzeVdriftT0();
121 if(ReadVdriftLinearFitGlobal(file)) AnalyzeVdriftLinearFit();
123 // 3. Append QA plots
125 //MakeDefaultPlots(fVdriftArray,fVdriftArray);
131 UpdateOCDBVdrift(startRunNumber,endRunNumber,ocdbStorage);
132 UpdateOCDBT0(startRunNumber,endRunNumber,ocdbStorage);
137 void AliTRDPreprocessorOffline::CalibGain(const Char_t* file, Int_t startRunNumber, Int_t endRunNumber, TString ocdbStorage){
139 // make calibration of the drift velocity
141 // file - the location of input file
142 // startRunNumber, endRunNumber - run validity period
143 // ocdbStorage - path to the OCDB storage
144 // - if empty - local storage 'pwd' uesed
145 if (ocdbStorage.Length()<=0) ocdbStorage="local://"+gSystem->GetFromPipe("pwd")+"/OCDB";
148 if(!ReadGainGlobal(file)) return;
151 // 2. extraction of the information
154 if(fCalDetGainUsed) CorrectFromDetGainUsed();
155 if(fCalDetVdriftUsed) CorrectFromDetVdriftUsed();
157 // 3. Append QA plots
159 //MakeDefaultPlots(fVdriftArray,fVdriftArray);
165 UpdateOCDBGain(startRunNumber,endRunNumber,ocdbStorage);
170 void AliTRDPreprocessorOffline::CalibPRF(const Char_t* file, Int_t startRunNumber, Int_t endRunNumber, TString ocdbStorage){
172 // make calibration of the drift velocity
174 // file - the location of input file
175 // startRunNumber, endRunNumber - run validity period
176 // ocdbStorage - path to the OCDB storage
177 // - if empty - local storage 'pwd' uesed
178 if (ocdbStorage.Length()<=0) ocdbStorage="local://"+gSystem->GetFromPipe("pwd")+"/OCDB";
181 if(!ReadPRFGlobal(file)) return;
184 // 2. extraction of the information
188 // 3. Append QA plots
190 //MakeDefaultPlots(fVdriftArray,fVdriftArray);
196 UpdateOCDBPRF(startRunNumber,endRunNumber,ocdbStorage);
200 Bool_t AliTRDPreprocessorOffline::Init(const Char_t* fileName){
202 // read the calibration used during the reconstruction
205 if(ReadVdriftT0Global(fileName)) {
207 TString nameph = fPH2d->GetTitle();
208 fVersionVdriftUsed = GetVersion(nameph);
209 fSubVersionVdriftUsed = GetSubVersion(nameph);
211 //printf("Found Version %d, Subversion %d for vdrift\n",fVersionVdriftUsed,fSubVersionVdriftUsed);
215 if(ReadGainGlobal(fileName)) {
217 TString namech = fCH2d->GetTitle();
218 fVersionGainUsed = GetVersion(namech);
219 fSubVersionGainUsed = GetSubVersion(namech);
221 //printf("Found Version %d, Subversion %d for gain\n",fVersionGainUsed,fSubVersionGainUsed);
230 Bool_t AliTRDPreprocessorOffline::ReadGainGlobal(const Char_t* fileName){
232 // read calibration entries from file
234 if(fCH2d) return kTRUE;
235 TFile fcalib(fileName);
236 TObjArray * array = (TObjArray*)fcalib.Get(fNameList);
238 TH2I *ch2d = (TH2I *) array->FindObject("CH2d");
239 if(!ch2d) return kFALSE;
240 fCH2d = (TH2I*)ch2d->Clone();
241 //fNEvents = (TH1I *) array->FindObject("NEvents");
242 //fAbsoluteGain = (TH2F *) array->FindObject("AbsoluteGain");
244 TH2I *ch2d = (TH2I *) fcalib.Get("CH2d");
245 if(!ch2d) return kFALSE;
246 fCH2d = (TH2I*)ch2d->Clone();
247 //fNEvents = (TH1I *) fcalib.Get("NEvents");
248 //fAbsoluteGain = (TH2F *) fcalib.Get("AbsoluteGain");
250 fCH2d->SetDirectory(0);
251 //printf("title of CH2d %s\n",fCH2d->GetTitle());
257 Bool_t AliTRDPreprocessorOffline::ReadVdriftT0Global(const Char_t* fileName){
259 // read calibration entries from file
261 if(fPH2d) return kTRUE;
262 TFile fcalib(fileName);
263 TObjArray * array = (TObjArray*)fcalib.Get(fNameList);
265 TProfile2D *ph2d = (TProfile2D *) array->FindObject("PH2d");
266 if(!ph2d) return kFALSE;
267 fPH2d = (TProfile2D*)ph2d->Clone();
268 //fNEvents = (TH1I *) array->FindObject("NEvents");
270 TProfile2D *ph2d = (TProfile2D *) fcalib.Get("PH2d");
271 if(!ph2d) return kFALSE;
272 fPH2d = (TProfile2D*)ph2d->Clone();
273 //fNEvents = (TH1I *) fcalib.Get("NEvents");
275 fPH2d->SetDirectory(0);
276 //printf("title of PH2d %s\n",fPH2d->GetTitle());
282 Bool_t AliTRDPreprocessorOffline::ReadVdriftLinearFitGlobal(const Char_t* fileName){
284 // read calibration entries from file
286 if(fAliTRDCalibraVdriftLinearFit) return kTRUE;
287 TFile fcalib(fileName);
288 TObjArray * array = (TObjArray*)fcalib.Get(fNameList);
290 fAliTRDCalibraVdriftLinearFit = (AliTRDCalibraVdriftLinearFit *) array->FindObject("AliTRDCalibraVdriftLinearFit");
291 //fNEvents = (TH1I *) array->FindObject("NEvents");
293 fAliTRDCalibraVdriftLinearFit = (AliTRDCalibraVdriftLinearFit *) fcalib.Get("AliTRDCalibraVdriftLinearFit");
294 //fNEvents = (TH1I *) fcalib.Get("NEvents");
296 if(!fAliTRDCalibraVdriftLinearFit) {
297 //printf("No AliTRDCalibraVdriftLinearFit\n");
304 Bool_t AliTRDPreprocessorOffline::ReadPRFGlobal(const Char_t* fileName){
306 // read calibration entries from file
308 if(fPRF2d) return kTRUE;
309 TFile fcalib(fileName);
310 TObjArray * array = (TObjArray*)fcalib.Get(fNameList);
312 TProfile2D *prf2d = (TProfile2D *) array->FindObject("PRF2d");
313 if(!prf2d) return kFALSE;
314 fPRF2d = (TProfile2D*)prf2d->Clone();
315 //fNEvents = (TH1I *) array->FindObject("NEvents");
317 TProfile2D *prf2d = (TProfile2D *) fcalib.Get("PRF2d");
318 if(!prf2d) return kFALSE;
319 fPRF2d = (TProfile2D*)prf2d->Clone();
320 //fNEvents = (TH1I *) fcalib.Get("NEvents");
322 fPRF2d->SetDirectory(0);
323 //printf("title of PRF2d %s\n",fPRF2d->GetTitle());
331 Bool_t AliTRDPreprocessorOffline::AnalyzeGain(){
333 // Analyze gain - produce the calibration objects
336 AliTRDCalibraFit *calibra = AliTRDCalibraFit::Instance();
337 calibra->SetMinEntries(800); // If there is less than 1000 entries in the histo: no fit
338 calibra->AnalyseCH(fCH2d);
340 Int_t nbtg = 6*4*18*((Int_t) ((AliTRDCalibraMode *)calibra->GetCalibraMode())->GetDetChamb0(0))
341 + 6* 18*((Int_t) ((AliTRDCalibraMode *)calibra->GetCalibraMode())->GetDetChamb2(0));
342 Int_t nbfit = calibra->GetNumberFit();
343 Int_t nbE = calibra->GetNumberEnt();
347 Bool_t meanother = kFALSE;
350 (nbfit >= 0.5*nbE) && (nbE > 30)) {
351 // create the cal objects
352 if(!fCalDetGainUsed) {
353 calibra->PutMeanValueOtherVectorFit(1,kTRUE);
356 TObjArray object = calibra->GetVectorFit();
357 AliTRDCalDet *calDetGain = calibra->CreateDetObjectGain(&object,meanother);
358 TH1F *coefGain = calDetGain->MakeHisto1DAsFunctionOfDet();
359 // Put them in the array
360 fCalibObjects->AddAt(calDetGain,kGain);
361 fPlots->AddAt(coefGain,kGain);
366 calibra->ResetVectorFit();
372 Bool_t AliTRDPreprocessorOffline::AnalyzeVdriftT0(){
374 // Analyze VdriftT0 - produce the calibration objects
377 AliTRDCalibraFit *calibra = AliTRDCalibraFit::Instance();
378 calibra->SetMinEntries(800*20); // If there is less than 1000 entries in the histo: no fit
379 calibra->AnalysePH(fPH2d);
381 Int_t nbtg = 6*4*18*((Int_t) ((AliTRDCalibraMode *)calibra->GetCalibraMode())->GetDetChamb0(1))
382 + 6* 18*((Int_t) ((AliTRDCalibraMode *)calibra->GetCalibraMode())->GetDetChamb2(1));
383 Int_t nbfit = calibra->GetNumberFit();
384 Int_t nbfitSuccess = calibra->GetNumberFitSuccess();
385 Int_t nbE = calibra->GetNumberEnt();
387 //printf("nbtg %d, nbfit %d, nbE %d, nbfitSuccess %d\n",nbtg,nbfit,nbE,nbfitSuccess);
391 (nbfit >= 0.5*nbE) && (nbE > 30) && (nbfitSuccess > 30)) {
392 //printf("Pass the cut for VdriftT0\n");
393 // create the cal objects
394 calibra->RemoveOutliers(1,kFALSE);
395 calibra->PutMeanValueOtherVectorFit(1,kFALSE);
396 calibra->RemoveOutliers2(kFALSE);
397 calibra->PutMeanValueOtherVectorFit2(1,kFALSE);
399 TObjArray object = calibra->GetVectorFit();
400 AliTRDCalDet *calDetVdrift = calibra->CreateDetObjectVdrift(&object);
401 TH1F *coefVdriftPH = calDetVdrift->MakeHisto1DAsFunctionOfDet();
402 AliTRDCalPad *calPadVdrift = (AliTRDCalPad *)calibra->CreatePadObjectVdrift(&object,calDetVdrift);
403 TH1F *coefPadVdrift = calPadVdrift->MakeHisto1D();
404 object = calibra->GetVectorFit2();
405 AliTRDCalDet *calDetT0 = calibra->CreateDetObjectT0(&object);
406 TH1F *coefT0 = calDetT0->MakeHisto1DAsFunctionOfDet();
407 AliTRDCalPad *calPadT0 = (AliTRDCalPad *)calibra->CreatePadObjectT0(&object,calDetT0);
408 TH1F *coefPadT0 = calPadT0->MakeHisto1D();
409 // Put them in the array
410 fCalibObjects->AddAt(calDetT0,kT0PHDet);
411 fCalibObjects->AddAt(calDetVdrift,kVdriftPHDet);
412 fCalibObjects->AddAt(calPadT0,kT0PHPad);
413 fCalibObjects->AddAt(calPadVdrift,kVdriftPHPad);
414 fPlots->AddAt(coefVdriftPH,kVdriftPHDet);
415 fPlots->AddAt(coefT0,kT0PHDet);
416 fPlots->AddAt(coefPadVdrift,kVdriftPHPad);
417 fPlots->AddAt(coefPadT0,kT0PHPad);
421 calibra->ResetVectorFit();
427 Bool_t AliTRDPreprocessorOffline::AnalyzeVdriftLinearFit(){
429 // Analyze vdrift linear fit - produce the calibration objects
432 AliTRDCalibraFit *calibra = AliTRDCalibraFit::Instance();
433 calibra->SetMinEntries(800); // If there is less than 1000 entries in the histo: no fit
434 fAliTRDCalibraVdriftLinearFit->FillPEArray();
435 calibra->AnalyseLinearFitters(fAliTRDCalibraVdriftLinearFit);
438 Int_t nbfit = calibra->GetNumberFit();
439 Int_t nbE = calibra->GetNumberEnt();
444 if ((nbfit >= 0.5*nbE) && (nbE > 30)) {
445 // create the cal objects
446 //calibra->RemoveOutliers(1,kTRUE);
447 calibra->PutMeanValueOtherVectorFit(1,kTRUE);
448 //calibra->RemoveOutliers2(kTRUE);
449 calibra->PutMeanValueOtherVectorFit2(1,kTRUE);
451 TObjArray object = calibra->GetVectorFit();
452 AliTRDCalDet *calDetVdrift = calibra->CreateDetObjectVdrift(&object,kTRUE);
453 TH1F *coefDriftLinear = calDetVdrift->MakeHisto1DAsFunctionOfDet();
454 object = calibra->GetVectorFit2();
455 AliTRDCalDet *calDetLorentz = calibra->CreateDetObjectLorentzAngle(&object);
456 TH1F *coefLorentzAngle = calDetLorentz->MakeHisto1DAsFunctionOfDet();
457 // Put them in the array
458 fCalibObjects->AddAt(calDetVdrift,kVdriftLinear);
459 fCalibObjects->AddAt(calDetLorentz,kLorentzLinear);
460 fPlots->AddAt(coefDriftLinear,kVdriftLinear);
461 fPlots->AddAt(coefLorentzAngle,kLorentzLinear);
466 calibra->ResetVectorFit();
473 Bool_t AliTRDPreprocessorOffline::AnalyzePRF(){
475 // Analyze PRF - produce the calibration objects
478 AliTRDCalibraFit *calibra = AliTRDCalibraFit::Instance();
479 calibra->SetMinEntries(600); // If there is less than 1000 entries in the histo: no fit
480 calibra->AnalysePRFMarianFit(fPRF2d);
482 Int_t nbtg = 6*4*18*((Int_t) ((AliTRDCalibraMode *)calibra->GetCalibraMode())->GetDetChamb0(2))
483 + 6* 18*((Int_t) ((AliTRDCalibraMode *)calibra->GetCalibraMode())->GetDetChamb2(2));
484 Int_t nbfit = calibra->GetNumberFit();
485 Int_t nbE = calibra->GetNumberEnt();
491 (nbfit >= 0.95*nbE) && (nbE > 30)) {
492 // create the cal objects
493 TObjArray object = calibra->GetVectorFit();
494 AliTRDCalPad *calPadPRF = (AliTRDCalPad*) calibra->CreatePadObjectPRF(&object);
495 TH1F *coefPRF = calPadPRF->MakeHisto1D();
496 // Put them in the array
497 fCalibObjects->AddAt(calPadPRF,kPRF);
498 fPlots->AddAt(coefPRF,kPRF);
503 calibra->ResetVectorFit();
509 void AliTRDPreprocessorOffline::CorrectFromDetGainUsed() {
511 // Correct from the gas gain used afterwards
513 AliTRDCalDet *calDetGain = (AliTRDCalDet *) fCalibObjects->At(kGain);
514 if(!calDetGain) return;
520 for(Int_t det = 0; det < 540; det++) {
522 Float_t gaininit = fCalDetGainUsed->GetValue(det);
523 Float_t gainout = calDetGain->GetValue(det);
526 if(TMath::Abs(gainout-1.0) > 0.000001) {
527 mean += (gaininit*gainout);
531 if(nbdet > 0) mean = mean/nbdet;
533 for(Int_t det = 0; det < 540; det++) {
535 Float_t gaininit = fCalDetGainUsed->GetValue(det);
536 Float_t gainout = calDetGain->GetValue(det);
538 if(TMath::Abs(gainout-1.0) > 0.000001) calDetGain->SetValue(det,gaininit*gainout);
539 else calDetGain->SetValue(det,mean);
545 void AliTRDPreprocessorOffline::CorrectFromDetVdriftUsed() {
547 // Correct from the drift velocity
550 //printf("Correct for vdrift\n");
552 AliTRDCalDet *calDetGain = (AliTRDCalDet *) fCalibObjects->At(kGain);
553 if(!calDetGain) return;
555 Int_t detVdrift = kVdriftPHDet;
556 if(fMethodSecond) detVdrift = kVdriftLinear;
557 AliTRDCalDet *calDetVdrift = (AliTRDCalDet *) fCalibObjects->At(detVdrift);
558 if(!calDetVdrift) return;
562 for(Int_t det = 0; det < 540; det++) {
564 Float_t vdriftinit = fCalDetVdriftUsed->GetValue(det);
565 Float_t vdriftout = calDetVdrift->GetValue(det);
567 Float_t gain = calDetGain->GetValue(det);
568 if(vdriftout > 0.0) gain = gain*vdriftinit/vdriftout;
569 calDetGain->SetValue(det,gain);
576 void AliTRDPreprocessorOffline::UpdateOCDBGain(Int_t startRunNumber, Int_t endRunNumber, const Char_t *storagePath){
581 AliCDBMetaData *metaData= new AliCDBMetaData();
582 metaData->SetObjectClassName("AliTRDCalDet");
583 metaData->SetResponsible("Raphaelle Bailhache");
584 metaData->SetBeamPeriod(1);
586 AliCDBId id1("TRD/Calib/ChamberGainFactor", startRunNumber, endRunNumber);
587 AliCDBStorage * gStorage = AliCDBManager::Instance()->GetStorage(storagePath);
588 AliTRDCalDet *calDet = (AliTRDCalDet *) fCalibObjects->At(kGain);
589 if(calDet) gStorage->Put(calDet, id1, metaData);
594 void AliTRDPreprocessorOffline::UpdateOCDBVdrift(Int_t startRunNumber, Int_t endRunNumber, const Char_t *storagePath){
599 Int_t detVdrift = kVdriftPHDet;
601 if(fMethodSecond) detVdrift = kVdriftLinear;
603 AliCDBMetaData *metaData= new AliCDBMetaData();
604 metaData->SetObjectClassName("AliTRDCalDet");
605 metaData->SetResponsible("Raphaelle Bailhache");
606 metaData->SetBeamPeriod(1);
608 AliCDBId id1("TRD/Calib/ChamberVdrift", startRunNumber, endRunNumber);
609 AliCDBStorage * gStorage = AliCDBManager::Instance()->GetStorage(storagePath);
610 AliTRDCalDet *calDet = (AliTRDCalDet *) fCalibObjects->At(detVdrift);
611 if(calDet) gStorage->Put(calDet, id1, metaData);
617 AliCDBMetaData *metaDataPad= new AliCDBMetaData();
618 metaDataPad->SetObjectClassName("AliTRDCalPad");
619 metaDataPad->SetResponsible("Raphaelle Bailhache");
620 metaDataPad->SetBeamPeriod(1);
622 AliCDBId id1Pad("TRD/Calib/LocalVdrift", startRunNumber, endRunNumber);
623 AliTRDCalPad *calPad = (AliTRDCalPad *) fCalibObjects->At(kVdriftPHPad);
624 if(calPad) gStorage->Put(calPad, id1Pad, metaDataPad);
630 void AliTRDPreprocessorOffline::UpdateOCDBT0(Int_t startRunNumber, Int_t endRunNumber, const Char_t *storagePath){
635 AliCDBMetaData *metaData= new AliCDBMetaData();
636 metaData->SetObjectClassName("AliTRDCalDet");
637 metaData->SetResponsible("Raphaelle Bailhache");
638 metaData->SetBeamPeriod(1);
640 AliCDBId id1("TRD/Calib/ChamberT0", startRunNumber, endRunNumber);
641 AliCDBStorage * gStorage = AliCDBManager::Instance()->GetStorage(storagePath);
642 AliTRDCalDet *calDet = (AliTRDCalDet *) fCalibObjects->At(kT0PHDet);
643 if(calDet) gStorage->Put(calDet, id1, metaData);
647 AliCDBMetaData *metaDataPad= new AliCDBMetaData();
648 metaDataPad->SetObjectClassName("AliTRDCalPad");
649 metaDataPad->SetResponsible("Raphaelle Bailhache");
650 metaDataPad->SetBeamPeriod(1);
652 AliCDBId id1Pad("TRD/Calib/LocalT0", startRunNumber, endRunNumber);
653 AliTRDCalPad *calPad = (AliTRDCalPad *) fCalibObjects->At(kT0PHPad);
654 if(calPad) gStorage->Put(calPad, id1Pad, metaDataPad);
660 void AliTRDPreprocessorOffline::UpdateOCDBPRF(Int_t startRunNumber, Int_t endRunNumber, const Char_t *storagePath){
665 AliCDBMetaData *metaData= new AliCDBMetaData();
666 metaData->SetObjectClassName("AliTRDCalPad");
667 metaData->SetResponsible("Raphaelle Bailhache");
668 metaData->SetBeamPeriod(1);
670 AliCDBId id1("TRD/Calib/PRFWidth", startRunNumber, endRunNumber);
671 AliCDBStorage * gStorage = AliCDBManager::Instance()->GetStorage(storagePath);
672 AliTRDCalPad *calPad = (AliTRDCalPad *) fCalibObjects->At(kPRF);
673 if(calPad) gStorage->Put(calPad, id1, metaData);
677 //_____________________________________________________________________________
678 Int_t AliTRDPreprocessorOffline::GetVersion(TString name) const
681 // Get version from the title
685 const Char_t *version = "Ver";
686 if(!strstr(name.Data(),version)) return -1;
688 for(Int_t ver = 0; ver < 999999999; ver++) {
690 TString vertry(version);
694 //printf("vertry %s and name %s\n",vertry.Data(),name.Data());
696 if(strstr(name.Data(),vertry.Data())) return ver;
704 //_____________________________________________________________________________
705 Int_t AliTRDPreprocessorOffline::GetSubVersion(TString name) const
708 // Get subversion from the title
712 const Char_t *subversion = "Subver";
713 if(!strstr(name.Data(),subversion)) return -1;
715 for(Int_t ver = 0; ver < 999999999; ver++) {
717 TString vertry(subversion);
721 //printf("vertry %s and name %s\n",vertry.Data(),name.Data());
723 if(strstr(name.Data(),vertry.Data())) return ver;