ROOT’s Python bindings, called PyROOT, allow to access all the ROOT C++ functionality from Python.
In order to make it easier to use ROOT from Python, or to use a more pythonic syntax, PyROOT provides many pythonizations for ROOT classes. A pythonization is a piece of code that injects some new behaviour in a ROOT class, e.g. to add new methods, to make the class iterable from Python or to override arithmetic operators. Pythonizations can be implemented in Python or in C++ (via the Python C/API).
Here you can
find the code for the current ROOT pythonizations. For example,
is adding Python item access methods to
TSeqCollection, more precisely by defining a pythonizor function, decorated
@pythonization, which injects the new methods in the class.
If you have an idea for a new pythonization that you think would be useful and need some guidance to write it, please let us know!
Addition of new pythonizations: code that injects new behaviour in ROOT classes when used from Python via PyROOT.
Good Python knowledge. Familiarity with the Python/C API is necessary if the pythonization is to be implemented in C++.