CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Namespaces | Functions
EcalPyUtils.cc File Reference
#include "DataFormats/EcalDetId/interface/EBDetId.h"
#include "DataFormats/EcalDetId/interface/EEDetId.h"
#include "CondTools/Ecal/interface/EcalFloatCondObjectContainerXMLTranslator.h"
#include <boost/python.hpp>
#include <boost/python/suite/indexing/vector_indexing_suite.hpp>

Go to the source code of this file.

Namespaces

 ecalpyutils
 

Functions

std::string ecalpyutils::arraystoXML (const std::vector< float > &eb, const std::vector< float > &ee)
 
 BOOST_PYTHON_MODULE (pluginEcalPyUtils)
 
int ecalpyutils::hashedIndex (int ieta, int iphi)
 
int ecalpyutils::hashedIndexEE (int ix, int iy, int iz)
 
std::vector< int > ecalpyutils::hashedIndexToEtaPhi (int hashedindex)
 
std::vector< int > ecalpyutils::hashedIndexToXY (int hashedindex)
 
int ecalpyutils::ism (int ieta, int iphi)
 

Function Documentation

BOOST_PYTHON_MODULE ( pluginEcalPyUtils  )

Definition at line 67 of file EcalPyUtils.cc.

References ecalpyutils::arraystoXML(), EcalFloatCondObjectContainerXMLTranslator::barrelfromXML(), def, EcalFloatCondObjectContainerXMLTranslator::endcapfromXML(), ecalpyutils::hashedIndex(), ecalpyutils::hashedIndexEE(), ecalpyutils::hashedIndexToEtaPhi(), ecalpyutils::hashedIndexToXY(), and ecalpyutils::ism().

67  {
68 
69 // looks like these are already defined somewhere
70 
71 // python access to stl integer vectors
72 // class_< std::vector<int> >("vectorInt")
73 // .def(vector_indexing_suite<std::vector<int> >())
74 // ;
75 
76 // class_< std::vector<float> >("vectorFloat")
77 // .def(vector_indexing_suite<std::vector<float> >())
78 // ;
79 
80  def("hashedIndexToEtaPhi",&ecalpyutils::hashedIndexToEtaPhi);
81  def("hashedIndexToXY",&ecalpyutils::hashedIndexToXY);
82  def("hashedIndex",&ecalpyutils::hashedIndex);
83  def("hashedIndexEE",&ecalpyutils::hashedIndexEE);
84  def("ism",&ecalpyutils::ism);
87  def("arraystoXML",&ecalpyutils::arraystoXML);
88 }
static std::vector< float > barrelfromXML(const std::string &filename)
int hashedIndex(int ieta, int iphi)
Definition: EcalPyUtils.cc:42
int hashedIndexEE(int ix, int iy, int iz)
Definition: EcalPyUtils.cc:47
std::string arraystoXML(const std::vector< float > &eb, const std::vector< float > &ee)
Definition: EcalPyUtils.cc:61
static std::vector< float > endcapfromXML(const std::string &filename)
std::vector< int > hashedIndexToXY(int hashedindex)
Definition: EcalPyUtils.cc:30
std::vector< int > hashedIndexToEtaPhi(int hashedindex)
Definition: EcalPyUtils.cc:21
int ism(int ieta, int iphi)
Definition: EcalPyUtils.cc:56
JetCorrectorParameters::Definitions def
Definition: classes.h:12