]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HLT/TPCLib/AliHLTTPCTrackHistoComponent.h
Qmax for merged clusters fixed
[u/mrichter/AliRoot.git] / HLT / TPCLib / AliHLTTPCTrackHistoComponent.h
index 794a9f543a2e49d2c21f44cb576012218645dd5a..779c6c58133fd419261fb32cc45df3124a0b4cfa 100644 (file)
 /** @file   AliHLTTPCTrackHistoComponent.h
     @author Gaute Ovrebekk
     @date   
-    @brief  Component for ploting charge in clusters
+    @brief  Component for track histo
 */
 
 #include "AliHLTProcessor.h"
 #include "AliHLTTPCSpacePointData.h"
 #include "AliHLTTPCTrackSegmentData.h"
 
-class AliHLTTPCConfMapper;
+class TNtuple;
 class TH1F;
+class TProfile;
 
 /**
  * @class AliHLTTPCTrackHistoComponent
- * Component for ploting proparties of Tracks. 
- * There has to be uesd one argument, or the component will not plot anything.
+ * Component for plotting proparties of Tracks. 
+ * The component gives out 2 NTuples. One for cluster and one for track properties
  * 
  * <h2>General properties:</h2> 
  *
  * Component ID: \b TPCTrackHisto <br>
  * Library: \b libAliHLTTPC.so <br>
  * Input Data Types: AliHLTTPCDefinitions::fgkClustersDataType,
- *                   AliHLTTPCDefinitions::fgkTrackSegmentsDataType or
  *                   AliHLTTPCDefinitions::fgkTracksDataType <br>
- * Output Data Types: @ref kAliHLTDataTypeHistogram <br> 
+ * Output Data Types: ::kAliHLTDataTypeTNtuple <br> 
  *
  * <h2> Mandatory arguments: </h2>
- * \li One of the Optional arguments.
+ * \li No mandaroty arguments. 
  * 
  * <h2> Optional arguments: </h2>
  * 
- * \li -plot-All <br>
- *      Plots all the Histograms (default kFALSE) 
- * \li -plot-nClusters <br>
- *      Plots Number of Clusters on Tracks (default kFALSE)
- * \li -plot-ChargeClusters <br>
- *      Plots Charge on all Clusters (default kFALSE)
- * \li -plot-ChargeUsedClusters <br>
- *      Plots Charge on Clusters used for Tracks (default kFALSE)
- * \li -plot-pT <br>
- *      Plots pT for Tracks (default kFALSE)
- * \li -plot-Residuals <br>
- *      Plots Residual of Tracks (default kFALSE)
- * \li -plot-Tgl <br>
- *      Plots Tgl for tracks (default kFALSE)
- * \li -plot-NClusters <br>
- *      Plots the number of clusters in the event (default kFALSE)
- * \li -plot-NUsedClusters <br>
- *      Plots th number of Used clusters in the event (default kFALSE)
- * \li -plot-NTracks <br>
- *      Plots the number of Tracks in the event (default kFALSE)
- * \li -plot-QMaxAll <br>
- *      Plots the Q Max for all clusters in the event (default kFALSE)
- * \li -plot-QMaxUsed <br>
- *      Plots the Q Max for clusters used on tracks (default kFALSE)
- * \li -reset-plots <br>
- *      Will reset the plots for every event (default kFALSE)
- *
  * <h2>Configuration:</h2>
  * 
  *
@@ -79,9 +52,7 @@ class TH1F;
  * Not Tested
  *
  * <h2>Output size:</h2>
- * The size of an histogram (588 bit) * the number of histograms you plot
- *
- * 
+ * Size variables in Ntuple
  *
  * @ingroup alihlt_tpc_components
  */
@@ -103,9 +74,13 @@ public:
   /** interface function, see AliHLTComponent for description */
   AliHLTComponentDataType GetOutputDataType();
   /** interface function, see AliHLTComponent for description */
+  int GetOutputDataTypes(AliHLTComponentDataTypeList& tgtList);
+  /** interface function, see AliHLTComponent for description */
   virtual void GetOutputDataSize( unsigned long& constBase, double& inputMultiplier );
   /** interface function, see AliHLTComponent for description */
   AliHLTComponent* Spawn();
+  /** interface function, see @ref AliHLTComponent for description */
+  void GetOCDBObjectDescription( TMap* const targetMap);
 
 protected:
 
@@ -119,6 +94,10 @@ protected:
   int DoDeinit();
   /** interface function, see AliHLTComponent for description */
   int DoEvent( const AliHLTComponentEventData& /*evtData*/, AliHLTComponentTriggerData& trigData );
+  /** inherited from AliHLTComponent: handle re-configuration event */
+  int Reconfigure(const char* cdbEntry, const char* chainId);
+  /** inherited from AliHLTComponent, scan one argument and its parameters */
+  int ScanConfigurationArgument(int argc, const char** argv);
 
   using AliHLTProcessor::DoEvent;
   
@@ -132,42 +111,35 @@ private:
    * Parse a string for the configuration arguments and set the component
    * properties.
    */ 
-  int Configure(const char* arguments);
+  
   void ReadTracks(const AliHLTComponentBlockData* iter,Int_t &tt);
 
   void PushHisto();
  
-  TH1F * fHistoNClustersOnTracks;                                  //! transient
-  TH1F * fHistoChargeAllClusters;                                  //! transient
-  TH1F * fHistoChargeUsedClusters;                                 //! transient
-  TH1F * fHistoPT;                                                 //! transient
-  TH1F * fHistoResidual;                                           //! transient
-  TH1F * fHistoTgl;                                                //! transient
-  TH1F * fHistoNClusters;                                          //! transient
-  TH1F * fHistoNUsedClusters;                                      //! transient
-  TH1F * fHistoNTracks;                                            //! transient 
-  TH1F * fHistoQMaxAllClusters;                                    //! transient
-  TH1F * fHistoQMaxUsedClusters;                                   //! transient
-  
-  Bool_t fPlotAll;                                                 //! transient 
-  Bool_t fPlotNClustersOnTracks;                                   //! transient 
-  Bool_t fPlotChargeClusters;                                      //! transient 
-  Bool_t fPlotChargeUsedClusters;                                  //! transient 
-  Bool_t fPlotPT;                                                  //! transient 
-  Bool_t fPlotResidual;                                            //! transient 
-  Bool_t fPlotTgl;                                                 //! transient 
-  Bool_t fPlotNClusters;                                           //! transient
-  Bool_t fPlotNUsedClusters;                                       //! transient
-  Bool_t fPlotNTracks;                                             //! transient
-  Bool_t fPlotQMaxClusters;                                        //! transient
-  Bool_t fPlotQMaxUsedClusters;                                    //! transient
-  Bool_t fResetPlots;                                              //! transient
-
-  vector<AliHLTTPCSpacePointData> fClusters;                       //! transient
-  vector<AliHLTTPCTrackSegmentData> fTracks;                       //! transient
+  Int_t fNEvents;    //! transient
+  Int_t fNtotTracks; //! transient
+
+  Int_t fEvtMod;     //! number of events reached to reset the counter
+  Int_t fBufferSize; //! size of circular buffer (number of entries) for the ntuples
+  Bool_t fdEdx;      //! plot dEdx
+  //  Bool_t fReset;  //! Reset track counter every certain events
+
+  TH1F *fMeanMultiplicity; //! transient (mean multiplicity for every 20 evts vs. #evt by Z.Y.)
+  TH1F *fMultiplicity;     //! transient (track multiplicity by Z.Y.)
+  //TH1F *fdNdEta;           //! transient (dN/dEta)
+     
+  //TH2F *fNClusterVsXY;   //! transient (#Clusters vs. x, y positions, by ZY)
+  //TH2F *fChargeVsXY;     //! transient (Charge distr. vs. x, y added by ZY)
+  TProfile *fDeDxVsP;    //! transient (dEdX vs. p)
+
+  TNtuple *fClusters;                             //! transient  
+  TNtuple *fTracks;                               //! transient
+
+  AliHLTTPCSpacePointData *fClustersArray[36][6]; //! transient
+  UInt_t                   fNSpacePoints[36][6];  //! transient
   
-  vector<UInt_t> fTrackClusterID[36][6];                           //! transient
+  /** the default configuration entry for this component */
+  static const char* fgkOCDBEntry; //!transient
 
   ClassDef(AliHLTTPCTrackHistoComponent, 0);