Geant4-11
Namespaces | Functions
pyRandomize.cc File Reference
#include <boost/python.hpp>
#include "Randomize.hh"
#include <vector>

Go to the source code of this file.

Namespaces

namespace  pyRandomize
 

Functions

void export_Randomize ()
 
int pyRandomize::f1_RandBit_shootBit ()
 
double pyRandomize::f1_RandGaussQ_shoot ()
 
void pyRandomize::f1_restoreEngineStatus ()
 
void pyRandomize::f1_saveEngineStatus ()
 
void pyRandomize::f1_setTheSeed (long seed)
 
void pyRandomize::f1_setTheSeeds (const list &seedList)
 
double pyRandomize::f2_RandGaussQ_shoot (double mean, double stdDev)
 
void pyRandomize::f2_restoreEngineStatus (const char *filename)
 
void pyRandomize::f2_saveEngineStatus (const char *filename)
 
void pyRandomize::f2_setTheSeed (long seed, int lux)
 
void pyRandomize::f2_setTheSeeds (const list &seedList, int aux)
 
double pyRandomize::f_G4UniformRand ()
 
list pyRandomize::f_getTheSeeds ()
 
list pyRandomize::f_getTheTableSeeds (int index)
 

Function Documentation

◆ export_Randomize()

void export_Randomize ( )

Definition at line 176 of file pyRandomize.cc.

177{
178 class_<HepRandom>("HepRandom", "generate random number")
179 // ---
180 .def(init<long>())
181 .def(init<HepRandomEngine&>())
182 .def(init<HepRandomEngine*>())
183 // ---
184 .def("setTheSeed", f1_setTheSeed)
185 .def("setTheSeed", f2_setTheSeed)
186 .staticmethod("setTheSeed")
187 .def("getTheSeed", &HepRandom::getTheSeed)
188 .staticmethod("getTheSeed")
189 .def("setTheSeeds", f1_setTheSeeds)
190 .def("setTheSeeds", f2_setTheSeeds)
191 .staticmethod("setTheSeeds")
192 .def("getTheSeeds", f_getTheSeeds)
193 .staticmethod("getTheSeeds")
194 .def("getTheTableSeeds", f_getTheTableSeeds)
195 .staticmethod("getTheTableSeeds")
196 // ---
197 .def("getTheGenerator", &HepRandom::getTheGenerator,
198 return_value_policy<reference_existing_object>())
199 .staticmethod("getTheGenerator")
200 .def("setTheEngine", &HepRandom::setTheEngine)
201 .staticmethod("setTheEngine")
202 .def("getTheEngine", &HepRandom::getTheEngine,
203 return_value_policy<reference_existing_object>())
204 .staticmethod("getTheEngine")
205 .def("saveEngineStatus", f1_saveEngineStatus)
206 .def("saveEngineStatus", f2_saveEngineStatus)
207 .staticmethod("saveEngineStatus")
208 .def("restoreEngineStatus", f1_restoreEngineStatus)
209 .def("restoreEngineStatus", f2_restoreEngineStatus)
210 .staticmethod("restoreEngineStatus")
211 .def("showEngineStatus", &HepRandom::showEngineStatus)
212 .staticmethod("showEngineStatus")
213 .def("createInstance", &HepRandom::createInstance)
214 .staticmethod("createInstance")
215 ;
216
217 // ---
218 class_<RandBit, boost::noncopyable>
219 ("RandBit", "generate bit random number", no_init)
220 .def("shootBit", f1_RandBit_shootBit)
221 .staticmethod("shootBit")
222 ;
223
224 // ---
225 class_<G4RandGauss, boost::noncopyable>
226 ("G4RandGauss", "generate gaussian random number", no_init)
227 .def("shoot", f1_RandGaussQ_shoot)
228 .def("shoot", f2_RandGaussQ_shoot)
229 .staticmethod("shoot")
230 ;
231
232 // ---
233 def("G4UniformRand", f_G4UniformRand);
234
235}
double f2_RandGaussQ_shoot(double mean, double stdDev)
Definition: pyRandomize.cc:157
void f2_setTheSeed(long seed, int lux)
Definition: pyRandomize.cc:50
void f2_setTheSeeds(const list &seedList, int aux)
Definition: pyRandomize.cc:76
list f_getTheTableSeeds(int index)
Definition: pyRandomize.cc:110
void f1_setTheSeeds(const list &seedList)
Definition: pyRandomize.cc:56
void f2_saveEngineStatus(const char *filename)
Definition: pyRandomize.cc:129
list f_getTheSeeds()
Definition: pyRandomize.cc:96
double f1_RandGaussQ_shoot()
Definition: pyRandomize.cc:152
void f1_restoreEngineStatus()
Definition: pyRandomize.cc:135
void f2_restoreEngineStatus(const char *filename)
Definition: pyRandomize.cc:140
int f1_RandBit_shootBit()
Definition: pyRandomize.cc:146
void f1_setTheSeed(long seed)
Definition: pyRandomize.cc:45
void f1_saveEngineStatus()
Definition: pyRandomize.cc:124
double f_G4UniformRand()
Definition: pyRandomize.cc:164

References pyRandomize::f1_RandBit_shootBit(), pyRandomize::f1_RandGaussQ_shoot(), pyRandomize::f1_restoreEngineStatus(), pyRandomize::f1_saveEngineStatus(), pyRandomize::f1_setTheSeed(), pyRandomize::f1_setTheSeeds(), pyRandomize::f2_RandGaussQ_shoot(), pyRandomize::f2_restoreEngineStatus(), pyRandomize::f2_saveEngineStatus(), pyRandomize::f2_setTheSeed(), pyRandomize::f2_setTheSeeds(), pyRandomize::f_G4UniformRand(), pyRandomize::f_getTheSeeds(), and pyRandomize::f_getTheTableSeeds().

Referenced by BOOST_PYTHON_MODULE().