#include "Cal/AliTRDCalROC.h"
#include "Cal/AliTRDCalPad.h"
#include "Cal/AliTRDCalDet.h"
-#include "Cal/AliTRDCalGlobals.h"
-#include "Cal/AliTRDCalPIDLQ.h"
+#include "Cal/AliTRDCalFEE.h"
+#include "Cal/AliTRDCalPID.h"
#include "Cal/AliTRDCalMonitoring.h"
#include "Cal/AliTRDCalChamberStatus.h"
#include "Cal/AliTRDCalPadStatus.h"
case kIDMonitoringData :
return CacheCDBEntry(kIDMonitoringData ,"TRD/Calib/MonitoringData");
break;
- case kIDGlobals :
- return CacheCDBEntry(kIDGlobals ,"TRD/Calib/Globals");
+ case kIDFEE :
+ return CacheCDBEntry(kIDFEE ,"TRD/Calib/FEE");
break;
+ case kIDPIDNN :
+ return CacheCDBEntry(kIDPIDNN ,"TRD/Calib/PIDNN");
case kIDPIDLQ :
return CacheCDBEntry(kIDPIDLQ ,"TRD/Calib/PIDLQ");
break;
return calChamber->GetValue(det) * roc->GetValue(col,row);
}
+
+//_____________________________________________________________________________
+AliTRDCalROC *AliTRDcalibDB::GetVdriftROC(Int_t det)
+{
+ //
+ // Returns the Vdrift calibration object for a given ROC
+ // containing one number per pad
+ //
+
+ const AliTRDCalPad *calPad = dynamic_cast<const AliTRDCalPad *>
+ (GetCachedCDBObject(kIDVdriftPad));
+ if (!calPad) {
+ return 0;
+ }
+
+ AliTRDCalROC *roc = calPad->GetCalROC(det);
+ if (!roc) {
+ return 0;
+ }
+ else {
+ return roc;
+ }
+
+}
+
+//_____________________________________________________________________________
+const AliTRDCalDet *AliTRDcalibDB::GetVdriftDet()
+{
+ //
+ // Returns the Vdrift calibration object
+ // containing one number per detector
+ //
+
+ const AliTRDCalDet *calChamber = dynamic_cast<const AliTRDCalDet *>
+ (GetCachedCDBObject(kIDVdriftChamber));
+ if (!calChamber) {
+ return 0;
+ }
+ else {
+ return calChamber;
+ }
+
+}
//_____________________________________________________________________________
Float_t AliTRDcalibDB::GetVdriftAverage(Int_t det)
return calChamber->GetValue(det) + roc->GetValue(col,row);
}
-
+
//_____________________________________________________________________________
AliTRDCalROC *AliTRDcalibDB::GetT0ROC(Int_t det)
{
}
+//_____________________________________________________________________________
+AliTRDCalROC *AliTRDcalibDB::GetPRFROC(Int_t det)
+{
+ //
+ // Returns the PRF calibration object for a given ROC
+ // containing one number per pad
+ //
+
+ const AliTRDCalPad *calPad = dynamic_cast<const AliTRDCalPad *>
+ (GetCachedCDBObject(kIDPRFWidth));
+ if (!calPad) {
+ return 0;
+ }
+
+ AliTRDCalROC *roc = calPad->GetCalROC(det);
+ if (!roc) {
+ return 0;
+ }
+ else {
+ return roc;
+ }
+
+}
+
//_____________________________________________________________________________
Float_t AliTRDcalibDB::GetPRFWidth(Int_t det, Int_t col, Int_t row)
{
// Returns the number of time bins which are read-out.
//
- const AliTRDCalGlobals *calGlobal = dynamic_cast<const AliTRDCalGlobals *>
- (GetCachedCDBObject(kIDGlobals));
- if (!calGlobal) {
+ const AliTRDCalFEE *calFEE = dynamic_cast<const AliTRDCalFEE *>
+ (GetCachedCDBObject(kIDFEE));
+ if (!calFEE) {
return -1;
}
- return calGlobal->GetNumberOfTimeBins();
+ return calFEE->GetNumberOfTimeBins();
}
// Returns the status of the given pad
//
- const AliTRDCalPadStatus *cal = dynamic_cast<const AliTRDCalPadStatus *>
- (GetCachedCDBObject(kIDPadStatus));
+ const AliTRDCalPadStatus *cal = dynamic_cast<const AliTRDCalPadStatus *>
+ (GetCachedCDBObject(kIDPadStatus));
if (!cal) {
return -1;
}
}
//_____________________________________________________________________________
-const AliTRDCalPIDLQ *AliTRDcalibDB::GetPIDLQObject()
+const AliTRDCalPID *AliTRDcalibDB::GetPIDObject(const Int_t method)
{
//
// Returns the object storing the distributions for PID with likelihood
//
- return dynamic_cast<const AliTRDCalPIDLQ *>
- (GetCachedCDBObject(kIDPIDLQ));
+ switch(method) {
+ case 0: return dynamic_cast<const AliTRDCalPID *>
+ (GetCachedCDBObject(kIDPIDNN));
+ case 1: return dynamic_cast<const AliTRDCalPID *>
+ (GetCachedCDBObject(kIDPIDLQ));
+ }
+
+ return 0;
}