13 """ GaudiPython.Bindings module.
14 This module provides the basic bindings of the main Gaudi
15 components to Python. It is itself based on the ROOT cppyy
16 Python extension module.
18 from __future__
import absolute_import, print_function
52 from GaudiKernel
import ROOT6WorkAroundEnabled
55 with warnings.catch_warnings():
56 warnings.simplefilter(
"ignore")
59 if sys.version_info >= (3,):
71 from GaudiKernel.Proxy.Configurable
import Configurable, getNeededConfigurables
73 from .
import Pythonizations
82 gbl.gInterpreter.Declare(
'#include "Gaudi/Property.h"')
83 Helper = gbl.GaudiPython.Helper
84 StringProperty = gbl.Gaudi.Property(
"std::string")
85 StringPropertyRef = gbl.Gaudi.Property(
"std::string&")
86 GaudiHandleProperty = gbl.GaudiHandleProperty
87 GaudiHandleArrayProperty = gbl.GaudiHandleArrayProperty
88 DataObject = gbl.DataObject
89 SUCCESS = gbl.StatusCode(gbl.StatusCode.SUCCESS)
90 FAILURE = gbl.StatusCode(gbl.StatusCode.FAILURE)
92 if hasattr(cppyy,
"nullptr"):
93 nullptr = cppyy.nullptr
94 elif hasattr(gbl,
"nullptr"):
99 cppyy.gbl.gInterpreter.Declare(
102 namespace GaudiPython { namespace Helpers {
103 void setProperty(ISvcLocator* svcLoc, std::string key, std::string value) {
104 if ( !svcLoc ) throw std::runtime_error( "invalid ISvcLocator pointer" );
105 svcLoc->getOptsSvc().set(key, value);
112 for l
in [l
for l
in dir(Helper)
if re.match(
"^to.*Array$", l)]:
113 exec(
"%s = Helper.%s" % (l, l))
117 if hasattr(Helper,
"toArray"):
121 return getattr(Helper,
"toArray")
126 return getattr(Helper,
"toArray<%s>" % typ)
131 if hasattr(cppyy,
"libPyROOT"):
132 ROOT = cppyy.libPyROOT
135 makeNullPointer = ROOT.MakeNullPointer
136 setOwnership = ROOT.SetOwnership
140 warnings.warn(
"GaudiPython: " + message, DeprecationWarning, stacklevel=3)
147 """Helper class to obtain the adequate interface from a component
148 by using the Gaudi queryInterface() mechanism"""
159 if obj.queryInterface(self.
type.interfaceID(), ip).isSuccess():
163 "ERROR: queryInterface failed for", obj,
"interface:", self.
type
165 except Exception
as e:
169 "caught when retrieving interface",
176 traceback.print_stack()
188 InterfaceCast.__init__(self, t)
198 """Load a LCG dictionary using various mechanisms"""
199 if Helper.loadDynamicLib(dict) == 1:
205 raise ImportError(
"Error loading dictionary library")
213 Function to retrieve a certain C++ class by name and to load dictionary if requested
217 from gaudimodule import getClass
218 # one knows that class is already loaded
219 AppMgr = getClass( 'ApplicationMgr' )
220 # one knows where to look for class, if not loaded yet
221 MCParticle = getClass( 'MCParticle' , 'EventDict' )
222 # one knows where to look for class, if not loaded yet
223 Vertex = getClass( 'Vertex' , ['EventDict', 'PhysEventDict'] )
226 if hasattr(gbl, name):
227 return getattr(gbl, name)
229 if type(libs)
is not list:
233 if hasattr(gbl, name):
234 return getattr(gbl, name)
243 """holds the value and the documentation string of a property"""
249 if issubclass(
type(prop), GaudiHandleProperty):
251 elif issubclass(
type(prop), GaudiHandleArrayProperty):
252 self.
_value = prop.value()
256 self.
_value = eval(prop.toString(), {}, {})
258 if hasattr(prop,
"value"):
259 self.
_value = prop.value()
261 self.
_value = prop.toString()
263 self.
__doc__ +=
" --- Default value = " + str(self.
_value) +
" --- "
264 if prop.documentation() !=
"none":
276 "Return the underlying property itself"
290 """Python equivalent to the C++ Property interface"""
294 self.__dict__[
"_svcloc"] = gbl.Gaudi.svcLocator()
295 self.__dict__[
"_name"] = name
306 if not getattr(self, ifname):
307 self.retrieveInterface()
308 return getattr(getattr(self, ifname), method)(*args)
312 The method which is used for setting the property from the given value.
313 - In the case of the valid instance it sets the property through IProperty interface
314 - In the case of placeholder the property is added to JobOptionsCatalogue
316 if hasattr(value,
"toStringProperty"):
318 value = str(value.toStringProperty())
319 elif hasattr(value,
"toString"):
320 value = str(value.toString())
321 elif type(value) == long:
328 if not gbl.Gaudi.Utils.hasProperty(ip, name):
329 raise AttributeError(
"property %s does not exist" % name)
330 ip.setPropertyRepr(name, value)
332 gbl.GaudiPython.Helpers.setProperty(
333 self._svcloc,
".".join([self._name, name]), value
338 The method which returns the value for the given property
339 - In the case of the valid instance it returns the valid property value through IProperty interface
340 - In the case of placeholder the property value is retrieved from JobOptionsCatalogue
344 if not gbl.Gaudi.Utils.hasProperty(ip, name):
345 raise AttributeError(
"property %s does not exist" % name)
346 prop = ip.getProperty(name)
347 if StringProperty ==
type(prop):
349 elif StringPropertyRef ==
type(prop):
352 return eval(prop.toString(), {}, {})
356 opts = self._svcloc.getOptsSvc()
357 if opts.has(
"{}.{}".
format(self._name, name)):
359 return eval(opts.get(
"{}.{}".
format(self._name, name)), {}, {})
360 raise AttributeError(
"property %s does not exist" % name)
367 props = ip.getProperties()
368 propsFrom = self._name
370 raise NotImplementedError(
"rely on IJobOptionsSvc")
371 props = self._optsvc.getProperties(self._name)
372 propsFrom =
"jobOptionsSvc"
377 except (ValueError, TypeError)
as e:
379 "gaudimodule.iProperty.properties(): %s%s processing property %s.%s = %s"
380 % (e.__class__.__name__, e.args, propsFrom, p.name(), p.value())
392 """Python equivalent to IProperty interface"""
395 iProperty.__init__(self, name, isvc)
399 isvc = Helper.service(self._svcloc, self._name)
401 iService.__init__(self, self._name, isvc)
432 """Python equivalent to IAlgorithm interface"""
435 iProperty.__init__(self, name, ialg)
439 ialg = Helper.algorithm(
443 iAlgorithm.__init__(self, self._name, ialg)
492 """Python equivalent to IAlgTool interface (not completed yet)"""
495 iProperty.__init__(self, name, itool)
496 self.__dict__[
"_itool"] = itool
497 svc = Helper.service(self._svcloc,
"ToolSvc",
True)
498 self.__dict__[
"_toolsvc"] =
iToolSvc(
"ToolSvc", svc)
501 itool = self._toolsvc._retrieve(self._name)
503 iAlgTool.__init__(self, self._name, itool)
516 return self._itool.
name()
526 iService.__init__(self, name, idp)
527 self.__dict__[
"_idp"] =
InterfaceCast(gbl.IDataProviderSvc)(idp)
528 self.__dict__[
"_idm"] =
InterfaceCast(gbl.IDataManagerSvc)(idp)
532 raise AttributeError(
533 "C++ service %s does not exist" % self.__dict__[
"_name"]
535 return Helper.registerObject(self._idp, path, obj)
539 raise AttributeError(
540 "C++ service %s does not exist" % self.__dict__[
"_name"]
542 return Helper.unregisterObject(self._idp, path)
547 return Helper.dataobject(self._idp, path)
554 Get the existing object in TransientStore for the given location
556 - loading of object from persistency is NOT triggered
557 - 'data-on-demand' action is NOT triggered
559 >>> svc = ... ## get the service
560 >>> path = ... ## get the path in Transient Store
561 >>> data = svc.findObject ( path ) ## use the method
565 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
566 return Helper.findobject(self._idp, path)
571 Get object from Transient Store for the given location
574 - path : Location of object in Transient Store
575 - retrieve (bool) True : retrieve versus find
576 - disable on-demand (bool) False : temporary disable 'on-demand' actions
578 >>> svc = ... ## get the service
579 >>> path = ... ## get the path
581 >>> data = svc.getObject ( path , False ) ## find object in Transient Store
583 ## find object in Transient Store
584 # load form tape or use 'on-demand' action for missing objects :
585 >>> data = svc.getObject ( path , True )
587 ## find object in Transient Store
588 # load from tape or for missing objects, disable 'on-demand'-actions
589 >>> data = svc.getObject ( path , True , True )
593 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
594 return Helper.getobject(self._idp, path, *args)
598 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
599 return Helper.dataobject(self._idp, path)
603 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
608 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
612 if node == cppyy.nullptr:
614 ll = gbl.std.vector(
"IRegistry*")()
615 if type(node)
is str:
619 if self._idm.objectLeaves(node, ll).isSuccess():
622 def dump(self, node=cppyy.nullptr):
623 if node == cppyy.nullptr:
626 node = root.registry()
629 print(node.identifier())
631 for l
in self.
leaves(node):
634 def getList(self, node=cppyy.nullptr, lst=[], rootFID=None):
635 if node == cppyy.nullptr:
638 node = root.registry()
639 rootFID = node.address().
par()
643 Helper.dataobject(self._idp, node.identifier())
645 lst.append(node.identifier())
646 for l
in self.
leaves(node):
647 if l.address()
and l.address().
par() == rootFID:
654 if node == cppyy.nullptr:
657 node = root.registry()
662 Helper.dataobject(self._idp, node.identifier())
664 lst.append(node.identifier())
665 for l
in self.
leaves(node):
674 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
675 return self._idm.
setRoot(name, obj)
679 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
686 self.__dict__[
"_ihs"] =
InterfaceCast(gbl.IHistogramSvc)(ihs)
687 iDataSvc.__init__(self, name, ihs)
690 return Helper.histo1D(self._ihs, path)
693 return Helper.histo2D(self._ihs, path)
696 return Helper.histo3D(self._ihs, path)
699 return Helper.profile1D(self._ihs, path)
702 return Helper.profile2D(self._ihs, path)
706 Retrieve AIDA histogram or AIDA profile histogram by path in Histogram Transient Store
708 >>> histo = svc.retrieve ( 'path/to/my/histogram' )
723 Book the histograms(1D,2D&3D) , see IHistogramSvc::book
725 >>> histo = svc.book( .... )
727 return self._ihs.
book(*args)
731 Book the profile(1D&2D) histograms, see IHistogramSvc::bookProf
733 >>> histo = svc.bookProf( .... )
739 Retrieve the object from Histogram Transient Store (by path)
740 The reference to AIDA histogram is returned (if possible)
742 >>> histo = svc['path/to/my/histogram']
747 return iDataSvc.__getitem__(self, path)
751 Retrieve the histogram from Histogram Transient Store (by path)
752 The reference to AIDA histogram is returned (if possible)
754 >>> histo = svc.getAsAIDA ( 'path/to/my/histogram' )
760 Retrieve the histogram from Histogram Transient Store (by path)
761 The Underlying native ROOT object is returned (if possible)
763 >>> histo = svc.getAsROOT ( 'path/to/my/histogram' )
765 fun = gbl.Gaudi.Utils.Aida2ROOT.aida2root
778 iDataSvc.__init__(self, name, ints)
781 return self._ints.
book(*args)
784 """Defines the mapping between logical names and the output file
786 defineOutput({'LUN1':'MyFile1.root', 'LUN2':'Myfile2.root'}, svc='Gaudi::RootCnvSvc')
788 from .
import Persistency
as prs
790 helper = prs.get(typ)
791 helper.configure(
AppMgr())
792 self.
Output = [helper.formatOutput(files[lun], lun=lun)
for lun
in files]
793 if AppMgr().HistogramPersistency ==
"NONE":
794 AppMgr().HistogramPersistency =
"ROOT"
797 return iDataSvc.__getitem__(self, path)
804 iService.__init__(self, name, its)
807 sol = _gaudi.OutputLevel
810 if name.rfind(
".") == -1:
811 itool = Helper.tool(self._its,
"", name, nullptr,
False)
812 elif name[0:8] ==
"ToolSvc.":
813 itool = Helper.tool(self._its,
"", name[8:], nullptr,
False)
814 elif name.count(
".") > 1:
815 ptool = self.
_retrieve(name[: name.rfind(
".")])
817 self._its,
"", name[name.rfind(
".") + 1 :], ptool,
False
820 prop = _gaudi.property(name[: name.rfind(
".")])
822 self._its,
"", name[name.rfind(
".") + 1 :], prop._ip,
False
831 def create(self, typ, name=None, parent=nullptr, interface=None):
834 itool = Helper.tool(self._its, typ, name, parent,
True)
841 if type(itool)
is iAlgTool:
842 self._its.releaseTool(itool._itool)
853 Helper.service(gbl.Gaudi.svcLocator(),
"EventSelector"),
855 self.__dict__[
"g"] =
AppMgr()
857 def open(self, stream, typ="Gaudi::RootCnvSvc
", **kwargs):
858 from .
import Persistency
as prs
860 helper = prs.get(typ)
861 helper.configure(self.g)
862 self.
Input = helper.formatInput(stream, **kwargs)
877 newobj = object.__new__(cls)
878 cls.
__init__(newobj, *args, **kwargs)
910 self.__dict__[
"_exit_called"] =
False
912 self.__dict__[
"_gaudi_ns"] = Gaudi
914 from GaudiKernel.Proxy.Configurable
import expandvars
920 if dllname
and factname:
921 self.__dict__[
"_appmgr"] = gbl.Gaudi.createApplicationMgr(dllname, factname)
923 self.__dict__[
"_appmgr"] = gbl.Gaudi.createApplicationMgr(dllname)
925 self.__dict__[
"_appmgr"] = gbl.Gaudi.createApplicationMgr()
926 self.__dict__[
"_svcloc"] = gbl.Gaudi.svcLocator()
928 self.__dict__[
"_evtpro"] =
InterfaceCast(gbl.IEventProcessor)(self._appmgr)
929 self.__dict__[
"_svcmgr"] =
InterfaceCast(gbl.ISvcManager)(self._appmgr)
930 self.__dict__[
"pyalgorithms"] = []
931 iService.__init__(self,
"ApplicationMgr", self._appmgr)
933 if self.
FSMState() < Gaudi.StateMachine.CONFIGURED:
940 import GaudiKernel.Proxy.Configurable
942 if hasattr(GaudiKernel.Proxy.Configurable,
"applyConfigurableUsers"):
943 GaudiKernel.Proxy.Configurable.applyConfigurableUsers()
947 appMgr = Configurable.allConfigurables[
"ApplicationMgr"]
948 selfprops =
expandvars(appMgr.getValuedProperties())
951 for p, v
in selfprops.items():
953 for p, v
in selfoptions.items():
956 if outputlevel != -1:
960 ms = self.
service(
"MessageSvc")
961 if "MessageSvc" in Configurable.allConfigurables:
962 msprops = Configurable.allConfigurables[
"MessageSvc"]
963 ms = self.
service(
"MessageSvc")
964 if hasattr(msprops,
"getValuedProperties"):
965 msprops =
expandvars(msprops.getValuedProperties())
966 for p, v
in msprops.items():
968 if outputlevel != -1:
969 ms.OutputLevel = outputlevel
972 c = Configurable.allConfigurables[n]
973 if n
in [
"ApplicationMgr",
"MessageSvc"]:
975 for p, v
in c.getValuedProperties().
items():
979 hasattr(Configurable,
"PropertyReference")
980 and type(v) == Configurable.PropertyReference
989 gbl.GaudiPython.Helpers.setProperty(
990 self._svcloc,
".".join([n, p]), str(v)
992 if hasattr(Configurable,
"_configurationLocked"):
993 Configurable._configurationLocked =
True
998 atexit.register(self.
exit)
1004 orig_register = atexit.register
1006 def register(func, *targs, **kargs):
1007 orig_register(func, *targs, **kargs)
1008 if hasattr(func,
"__module__")
and func.__module__ ==
"ROOT":
1009 orig_register(self.
exit)
1013 register.__doc__ = (
1014 orig_register.__doc__
1015 +
"\nNote: version hacked by GaudiPython to work "
1016 +
"around a problem with the ROOT exit handler"
1018 atexit.register = register
1022 if "_svcloc" in self.__dict__:
1023 return self._svcloc.getOptsSvc()
1036 svc = Helper.service(self._svcloc, name)
1043 self._svcmgr.declareSvcType(svcname, svctype)
1046 return Helper.service(self._svcloc, name,
True)
1049 l = self._svcloc.getServices()
1050 return [s.name()
for s
in l]
1053 alg = Helper.algorithm(self._algmgr, name, createIf)
1060 l = self._algmgr.getAlgorithms()
1061 return [a.name()
for a
in l]
1075 if self.
state() == Gaudi.StateMachine.CONFIGURED:
1077 svc = Helper.service(self._svcloc, name)
1081 return self.
datasvc(
"EventDataSvc")
1084 return self.
datasvc(
"DetectorDataSvc")
1087 return self.
datasvc(
"FileRecordDataSvc")
1090 if self.
state() == Gaudi.StateMachine.CONFIGURED:
1092 if not hasattr(self,
"_evtsel"):
1097 svc = Helper.service(self._svcloc, name)
1101 if name
not in self.ExtSvc:
1102 self.ExtSvc += [name]
1104 svc = Helper.service(self._svcloc, name,
True)
1108 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1110 svc = Helper.service(self._svcloc,
"ParticlePropertySvc")
1114 svc = Helper.service(self._svcloc, name,
True)
1121 """Add an Algorithm to the list of Top algorithms. It can be either a instance of
1122 an Algorithm class or it name"""
1123 if type(alg)
is str:
1126 self.pyalgorithms.append(alg)
1132 self.
topAlg += [alg.name()]
1135 """Set the list of Top Algorithms.
1136 It can be an individual of a list of algorithms names or instances"""
1137 if type(algs)
is not list:
1141 if type(alg)
is str:
1144 self.pyalgorithms.append(alg)
1149 names.append(alg.name())
1153 """Remove an Algorithm to the list of Top algorithms. It can be either a instance of
1154 an Algorithm class or it name"""
1156 if type(alg)
is str:
1159 tmp.remove(alg.name())
1160 self.pyalgorithms.remove(alg)
1166 Print the sequence of Algorithms.
1169 def printAlgo(algName, appMgr, prefix=" "):
1170 print(prefix + algName)
1171 alg = appMgr.algorithm(algName.split(
"/")[-1])
1172 prop = alg.properties()
1173 if "Members" in prop:
1174 subs = prop[
"Members"].value()
1176 printAlgo(i.strip(
'"'), appMgr, prefix +
" ")
1179 prefix =
"ApplicationMgr SUCCESS "
1182 +
"****************************** Algorithm Sequence ****************************"
1184 for i
in mp[
"TopAlg"].value():
1185 printAlgo(i, self, prefix)
1188 +
"******************************************************************************"
1193 Simple utility to perform the configuration of Gaudi application.
1194 It reads the set of input job-options files, and set few
1195 additional parameters 'options' through the usage of temporary *.opts file
1197 gaudi.config( files = [ '$GAUSSOPTS/Gauss.opts' ,
1198 '$DECFILESROOT/options/10022_010.0GeV.opts' ] ,
1199 options = [ 'EventSelector.PrintFreq = 5 ' ] )
1201 files = args.get(
"files", [])
1205 raise RuntimeError(
' Unable to read file "' + file +
'" ')
1206 options = args.get(
"options",
None)
1210 tmpfilename = tempfile.mktemp()
1211 tmpfile = open(tmpfilename,
"w")
1212 tmpfile.write(
"#pragma print on \n")
1214 '/// File "' + tmpfilename +
'" generated by GaudiPython \n\n'
1217 if type(options)
is dict:
1223 +
" ; // added by GaudiPython \n"
1226 tmpfile.write(
" \t " + opt +
" ; // added by GaudiPython \n")
1228 '/// End of file "' + tmpfilename +
'" generated by GaudiPython \n\n'
1233 raise RuntimeError(
' Unable to read file "' + tmpfilename +
'" ')
1234 os.remove(tmpfilename)
1242 return self._appmgr.
start()
1248 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1250 if sc.isFailure()
or self.ReturnCode != 0:
1252 if self.
FSMState() == Gaudi.StateMachine.INITIALIZED:
1254 if sc.isFailure()
or self.ReturnCode != 0:
1256 return self._evtpro.executeRun(n)
1265 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1269 if self.
FSMState() == Gaudi.StateMachine.INITIALIZED:
1274 if not hasattr(self,
"_perssvc"):
1275 self.__dict__[
"_perssvc"] = self.
service(
1276 "EventPersistencySvc",
"IAddressCreator"
1278 if not hasattr(self,
"_filecat"):
1279 self.__dict__[
"_filecat"] = self.
service(
1280 "FileCatalog",
"Gaudi::IFileCatalog"
1282 if not hasattr(self,
"_evtmgr"):
1283 self.__dict__[
"_evtmgr"] = self.
service(
"EventDataSvc",
"IDataManagerSvc")
1285 if pfn.find(
"PFN:") == 0:
1289 if not self._filecat.existsFID(fid):
1290 self._filecat.registerPFN(fid, pfn,
"")
1292 if type(events)
is not list:
1296 gadd = gbl.GenericAddress(0x02, 1, fid,
"/Event", 0, evt)
1298 self._perssvc.createAddress(
1299 gadd.svcType(), gadd.clID(), gadd.par(), gadd.ipar(), oadd
1302 self._evtmgr.clearStore()
1303 self._evtmgr.setRoot(
"/Event", oadd)
1308 if not self._exit_called:
1309 self.__dict__[
"_exit_called"] =
True
1310 Gaudi = self._gaudi_ns
1311 if self.
FSMState() == Gaudi.StateMachine.RUNNING:
1312 self._appmgr.
stop().ignore()
1313 if self.
FSMState() == Gaudi.StateMachine.INITIALIZED:
1315 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1326 ntupleSvc = ntuplesvc
1337 tfile = gbl.TFile.Open(pfn)
1339 raise IOError(
"Cannot open ROOT file {0}".
format(pfn))
1340 tree = tfile.Get(
"##Params")
1342 text = tree.db_string
1343 if "NAME=FID" in text:
1344 fid = text[text.rfind(
"VALUE=") + 6 : -1]
1345 nevt = tfile.Get(
"_Event").GetEntries()
1354 """Get all the properties of a component as a Python dictionary.
1355 The component is instantiated using the component library
1358 if name ==
"GaudiCoreSvc":
1359 if Helper.loadDynamicLib(name) != 1:
1360 raise ImportError(
"Error loading component library " + name)
1361 factorylist = gbl.FactoryTable.instance().getEntries()
1363 g =
AppMgr(outputlevel=7)
1365 g =
AppMgr(outputlevel=7)
1366 if Helper.loadDynamicLib(name) != 1:
1367 raise ImportError(
"Error loading component library " + name)
1368 factorylist = gbl.FactoryTable.instance().getEntries()
1370 svcloc = gbl.Gaudi.svcLocator()
1371 dummysvc = gbl.Service(
"DummySvc", svcloc)
1372 for factory
in factories:
1379 elif factory.ident() ==
"ApplicationMgr":
1380 ctype =
"ApplicationMgr"
1383 cname = factory.ident().split()[-1]
1384 if ctype
in (
"Algorithm",
"Service",
"AlgTool",
"ApplicationMgr"):
1386 if ctype ==
"AlgTool":
1387 obj = factory.instantiate(dummysvc)
1389 obj = factory.instantiate(svcloc)
1390 except RuntimeError
as text:
1391 print(
"Error instantiating", cname,
" from ", name)
1395 properties[cname] = [ctype, prop.properties()]
1405 for i
in range(factories.size()):
1406 factory = factories.front()
1407 result.append(factory)
1408 factories.pop_front()
1409 for factory
in result:
1410 factories.push_back(factory)
1416 _CallbackStreamBufBase = gbl.GaudiPython.CallbackStreamBuf
1421 _CallbackStreamBufBase.__init__(self, self)
1433 _PyAlgorithm = gbl.GaudiPython.PyAlgorithm
1439 name = self.__class__.__name__
1440 _PyAlgorithm.__init__(self, self, name)
1443 sc = self.
_algmgr.addAlgorithm(self)
1445 raise RuntimeError(
"Unable to add Algorithm")
1448 sc = self.
_algmgr.removeAlgorithm(self)
1473 readline.parse_and_bind(
"tab: complete")