From 8ce2efb07820b285b0ed1cae0d61395a7ab5073e Mon Sep 17 00:00:00 2001 From: richterm Date: Mon, 29 Jun 2009 11:06:27 +0000 Subject: [PATCH] update by Gaute: - SPD and SSD cluster finders now load geometry from OCDB - Histogram component has SPD, SDD and SSD clusters as input --- HLT/ITS/AliHLTITSClusterFinderSPDComponent.cxx | 9 +++++++++ HLT/ITS/AliHLTITSClusterFinderSSDComponent.cxx | 9 +++++++++ HLT/ITS/AliHLTITSClusterHistoComponent.cxx | 11 +++++++++-- HLT/ITS/macros/rec-ssd-cluster.C | 8 ++++++-- 4 files changed, 33 insertions(+), 4 deletions(-) diff --git a/HLT/ITS/AliHLTITSClusterFinderSPDComponent.cxx b/HLT/ITS/AliHLTITSClusterFinderSPDComponent.cxx index 59a9767e84f..84b84806bb9 100644 --- a/HLT/ITS/AliHLTITSClusterFinderSPDComponent.cxx +++ b/HLT/ITS/AliHLTITSClusterFinderSPDComponent.cxx @@ -35,6 +35,7 @@ using namespace std; #include "AliHLTITSSpacePointData.h" #include "AliHLTITSClusterDataFormat.h" #include +#include "AliGeomManager.h" #include #include @@ -117,6 +118,14 @@ Int_t AliHLTITSClusterFinderSPDComponent::DoInit( int /*argc*/, const char** /*a fClusters[iModule] = NULL; } + AliCDBManager* man = AliCDBManager::Instance(); + AliGeomManager::LoadGeometry(); + + if (!man->IsDefaultStorageSet()){ + HLTError("Default CDB storage has not been set !"); + return -ENOENT; + } + //fgeomInit = new AliITSInitGeometry(kvSPD02,2); fgeomInit = new AliITSInitGeometry(kvPPRasymmFMD,2); //fgeomInit->InitAliITSgeom(fgeom); diff --git a/HLT/ITS/AliHLTITSClusterFinderSSDComponent.cxx b/HLT/ITS/AliHLTITSClusterFinderSSDComponent.cxx index 4615048589f..e4e500474f7 100644 --- a/HLT/ITS/AliHLTITSClusterFinderSSDComponent.cxx +++ b/HLT/ITS/AliHLTITSClusterFinderSSDComponent.cxx @@ -35,6 +35,7 @@ using namespace std; #include "AliHLTITSSpacePointData.h" #include "AliHLTITSClusterDataFormat.h" #include +#include "AliGeomManager.h" #include #include @@ -118,6 +119,14 @@ Int_t AliHLTITSClusterFinderSSDComponent::DoInit( int /*argc*/, const char** /*a fClusters[iModule] = NULL; } + AliCDBManager* man = AliCDBManager::Instance(); + AliGeomManager::LoadGeometry(); + + if (!man->IsDefaultStorageSet()){ + HLTError("Default CDB storage has not been set !"); + return -ENOENT; + } + //fgeomInit = new AliITSInitGeometry(kvSSD02,2); fgeomInit = new AliITSInitGeometry(kvPPRasymmFMD,2); //fgeomInit->InitAliITSgeom(fgeom); diff --git a/HLT/ITS/AliHLTITSClusterHistoComponent.cxx b/HLT/ITS/AliHLTITSClusterHistoComponent.cxx index a76b84cf644..ea7de6c1fd8 100644 --- a/HLT/ITS/AliHLTITSClusterHistoComponent.cxx +++ b/HLT/ITS/AliHLTITSClusterHistoComponent.cxx @@ -76,7 +76,9 @@ void AliHLTITSClusterHistoComponent::GetInputDataTypes(AliHLTComponentDataTypeLi { // see header file for class documentation list.clear(); - list.push_back( kAliHLTDataTypeTObjArray ); + list.push_back( kAliHLTDataTypeClusters|kAliHLTDataOriginITSSPD ); + list.push_back( kAliHLTDataTypeClusters|kAliHLTDataOriginITSSDD ); + list.push_back( kAliHLTDataTypeClusters|kAliHLTDataOriginITSSSD ); } AliHLTComponentDataType AliHLTITSClusterHistoComponent::GetOutputDataType() @@ -145,8 +147,13 @@ int AliHLTITSClusterHistoComponent::DoEvent(const AliHLTComponentEventData& /*ev if(!IsDataEvent()) return 0; - for ( iter = GetFirstInputBlock(kAliHLTDataTypeClusters|kAliHLTDataOriginITSSSD); iter != NULL; iter = GetNextInputBlock() ) { + for ( iter = GetFirstInputBlock(kAliHLTDataTypeClusters); iter != NULL; iter = GetNextInputBlock() ) { + if(iter->fDataType!=(kAliHLTAnyDataType|kAliHLTDataOriginITSSPD) && + iter->fDataType!=(kAliHLTAnyDataType|kAliHLTDataOriginITSSDD) && + iter->fDataType!=(kAliHLTAnyDataType|kAliHLTDataOriginITSSSD)) + continue; + const AliHLTITSClusterData* clusterData = (const AliHLTITSClusterData*) iter->fPtr; Int_t nSpacepoint = (Int_t) clusterData->fSpacePointCnt; TotalSpacePoint += nSpacepoint; diff --git a/HLT/ITS/macros/rec-ssd-cluster.C b/HLT/ITS/macros/rec-ssd-cluster.C index 873c0e89a71..a6c5719c534 100644 --- a/HLT/ITS/macros/rec-ssd-cluster.C +++ b/HLT/ITS/macros/rec-ssd-cluster.C @@ -54,9 +54,13 @@ void rec_ssd_cluster(const char* input="./", char* opt="") } //add dummy - AliHLTConfiguration dummyconf("dummy", "Dummy", dummyInput.Data(), "-output_percentage 0"); + //AliHLTConfiguration dummyconf("dummy", "Dummy", dummyInput.Data(), "-output_percentage 0"); + //option+="dummy"; - option+="dummy"; + AliHLTConfiguration cfconf("clusterHisto","ITSClusterHisto",dummyInput.Data(),""); + AliHLTConfiguration fwconf("histFile","ROOTFileWriter", "clusterHisto","-datafile ClusterHisto -concatenate-events -overwrite"); + + option+="histFile"; /////////////////////////////////////////////////////////////////////////////////////////////////// // -- 2.43.5