The Gaudi Framework  master (181af51f)
Loading...
Searching...
No Matches
GaudiPI.h
Go to the documentation of this file.
1/***********************************************************************************\
2* (c) Copyright 1998-2025 CERN for the benefit of the LHCb and ATLAS collaborations *
3* *
4* This software is distributed under the terms of the Apache version 2 licence, *
5* copied verbatim in the file "LICENSE". *
6* *
7* In applying this licence, CERN does not waive the privileges and immunities *
8* granted to it by virtue of its status as an Intergovernmental Organization *
9* or submit itself to any jurisdiction. *
10\***********************************************************************************/
11#pragma once
12
13#include <AIDA/IHistogram1D.h>
14#include <AIDA/IHistogram2D.h>
15#include <AIDA/IHistogram3D.h>
16#include <AIDA/IProfile1D.h>
17#include <AIDA/IProfile2D.h>
20#include <utility>
21#include <vector>
22
23class DataObject;
24class TH2D;
25
26namespace Gaudi {
27 typedef std::vector<double> Edges;
28
30 std::pair<DataObject*, AIDA::IHistogram1D*> createH1D( ISvcLocator* svcLocator, const std::string& path,
31 const AIDA::IHistogram1D& hist );
33 std::pair<DataObject*, AIDA::IHistogram1D*> createH1D( ISvcLocator* svcLocator, const std::string& path,
34 const std::string& title, int nBins = 10,
35 double lowerEdge = 0., double upperEdge = 1. );
37 std::pair<DataObject*, AIDA::IHistogram1D*> createH1D( ISvcLocator* svcLocator, const std::string& path,
38 const std::string& title, const Edges& e );
39
41 std::pair<DataObject*, AIDA::IHistogram2D*> createH2D( ISvcLocator* svcLocator, const std::string& path,
42 const AIDA::IHistogram2D& hist );
44 std::pair<DataObject*, AIDA::IHistogram2D*> createH2D( ISvcLocator* svcLocator, const std::string& path, TH2D* rep );
46 std::pair<DataObject*, AIDA::IHistogram2D*> createH2D( ISvcLocator* svcLocator, const std::string& path,
47 const std::string& title, int binsX, double iminX,
48 double imaxX, int binsY, double iminY, double imaxY );
50 std::pair<DataObject*, AIDA::IHistogram2D*> createH2D( ISvcLocator* svcLocator, const std::string& path,
51 const std::string& title, const Edges& eX, const Edges& eY );
53 std::pair<DataObject*, AIDA::IHistogram1D*> slice1DX( const std::string& name, const AIDA::IHistogram2D& h,
54 int firstbin, int lastbin );
56 std::pair<DataObject*, AIDA::IProfile1D*> profile1DX( const std::string& name, const AIDA::IHistogram2D& h,
57 int firstbin, int lastbin );
59 std::pair<DataObject*, AIDA::IHistogram1D*> project1DX( const std::string& name, const AIDA::IHistogram2D& h,
60 int firstbin, int lastbin );
62 std::pair<DataObject*, AIDA::IHistogram1D*> slice1DY( const std::string& name, const AIDA::IHistogram2D& h,
63 int firstbin, int lastbin );
65 std::pair<DataObject*, AIDA::IProfile1D*> profile1DY( const std::string& name, const AIDA::IHistogram2D& h,
66 int firstbin, int lastbin );
68 std::pair<DataObject*, AIDA::IHistogram1D*> project1DY( const std::string& name, const AIDA::IHistogram2D& h,
69 int firstbin, int lastbin );
70
72 std::pair<DataObject*, AIDA::IHistogram3D*> createH3D( ISvcLocator* svcLocator, const std::string& path,
73 const AIDA::IHistogram3D& hist );
75 std::pair<DataObject*, AIDA::IHistogram3D*> createH3D( ISvcLocator* svcLocator, const std::string& path,
76 const std::string& title, int nBinsX, double xlow, double xup,
77 int nBinsY, double ylow, double yup, int nBinsZ, double zlow,
78 double zup );
80 std::pair<DataObject*, AIDA::IHistogram3D*> createH3D( ISvcLocator* svcLocator, const std::string& path,
81 const std::string& title, const Edges& eX, const Edges& eY,
82 const Edges& eZ );
83
85 std::pair<DataObject*, AIDA::IProfile1D*> createProf1D( ISvcLocator* svcLocator, const std::string& path,
86 const AIDA::IProfile1D& hist );
88 std::pair<DataObject*, AIDA::IProfile1D*> createProf1D( ISvcLocator* svcLocator, const std::string& path,
89 const std::string& title, int nBins, double xlow, double xup,
90 double ylow, double yup, const std::string& opt = "" );
92 std::pair<DataObject*, AIDA::IProfile1D*> createProf1D( ISvcLocator* svcLocator, const std::string& path,
93 const std::string& title, const Edges& e, double ylow,
94 double yup, const std::string& opt = "" );
95
97 std::pair<DataObject*, AIDA::IProfile2D*> createProf2D( ISvcLocator* svcLocator, const std::string& path,
98 const AIDA::IProfile2D& hist );
100 std::pair<DataObject*, AIDA::IProfile2D*> createProf2D( ISvcLocator* svcLocator, const std::string& path,
101 const std::string& title, int binsX, double iminX,
102 double imaxX, int binsY, double iminY, double imaxY,
103 double lowerValue, double upperValue );
105 std::pair<DataObject*, AIDA::IProfile2D*> createProf2D( ISvcLocator* svcLocator, const std::string& path,
106 const std::string& title, const Edges& eX, const Edges& eY,
107 double lowerValue, double upperValue );
108} // namespace Gaudi
A DataObject is the base class of any identifiable object on any data store.
Definition DataObject.h:37
std::vector< double > Edges
Definition GaudiPI.h:27
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Definition ISvcLocator.h:42
This file provides a Grammar for the type Gaudi::Accumulators::Axis It allows to use that type from p...
Definition __init__.py:1
GAUDI_API ISvcLocator * svcLocator()
std::pair< DataObject *, AIDA::IHistogram2D * > createH2D(ISvcLocator *svcLocator, const std::string &path, const AIDA::IHistogram2D &hist)
Copy constructor.
std::pair< DataObject *, AIDA::IHistogram1D * > slice1DX(const std::string &name, const AIDA::IHistogram2D &h, int firstbin, int lastbin)
Create 1D slice from 2D histogram.
std::pair< DataObject *, AIDA::IHistogram1D * > project1DX(const std::string &name, const AIDA::IHistogram2D &h, int firstbin, int lastbin)
Create 1D projection in X from 2D histogram.
std::pair< DataObject *, AIDA::IHistogram1D * > slice1DY(const std::string &name, const AIDA::IHistogram2D &h, int firstbin, int lastbin)
Create 1D slice from 2D histogram.
std::pair< DataObject *, AIDA::IProfile2D * > createProf2D(ISvcLocator *svcLocator, const std::string &path, const AIDA::IProfile2D &hist)
Copy constructor.
std::pair< DataObject *, AIDA::IHistogram1D * > project1DY(const std::string &name, const AIDA::IHistogram2D &h, int firstbin, int lastbin)
Create 1D projection in Y from 2D histogram.
std::pair< DataObject *, AIDA::IProfile1D * > createProf1D(ISvcLocator *svcLocator, const std::string &path, const AIDA::IProfile1D &hist)
Copy constructor.
std::pair< DataObject *, AIDA::IHistogram3D * > createH3D(ISvcLocator *svcLocator, const std::string &path, const AIDA::IHistogram3D &hist)
Copy constructor.
std::pair< DataObject *, AIDA::IProfile1D * > profile1DX(const std::string &name, const AIDA::IHistogram2D &h, int firstbin, int lastbin)
Create 1D profile in X from 2D histogram.
std::pair< DataObject *, AIDA::IProfile1D * > profile1DY(const std::string &name, const AIDA::IHistogram2D &h, int firstbin, int lastbin)
Create 1D profile in Y from 2D histogram.
std::pair< DataObject *, AIDA::IHistogram1D * > createH1D(ISvcLocator *svcLocator, const std::string &path, const AIDA::IHistogram1D &hist)
Copy constructor.