CMS 3D CMS Logo

Namespaces | Functions

/data/refman/pasoursint/CMSSW_6_1_1/src/CondCore/EcalPlugins/plugins/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

namespace  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().

                                       {

//   looks like these are already defined somewhere

//   python access to stl integer vectors 
//   class_< std::vector<int> >("vectorInt") 
//     .def(vector_indexing_suite<std::vector<int> >()) 
//   ; 

//   class_< std::vector<float> >("vectorFloat") 
//     .def(vector_indexing_suite<std::vector<float> >()) 
//   ; 

  def("hashedIndexToEtaPhi",&ecalpyutils::hashedIndexToEtaPhi);
  def("hashedIndexToXY",&ecalpyutils::hashedIndexToXY);
  def("hashedIndex",&ecalpyutils::hashedIndex);
  def("hashedIndexEE",&ecalpyutils::hashedIndexEE);
  def("ism",&ecalpyutils::ism);
  def("barrelfromXML",&EcalFloatCondObjectContainerXMLTranslator::barrelfromXML);
  def("endcapfromXML",&EcalFloatCondObjectContainerXMLTranslator::endcapfromXML);
  def("arraystoXML",&ecalpyutils::arraystoXML);
}