Towards a "functional" approach #32
Labels
Feature Request
originally gitlab
For items that were originally created on gitlab and imported over
Performance Improvement
Stage: BinnedDataFrame
Stage: Event Selections
Stage: User Scribblers
Stage: Variable Defining
Milestone
Imported from gitlab issue 32
A more functional approach would be helpful in removing state and making it easier to pipeline and optimise the stage sequence.
There are a few changes to the existing code that would help move us in that direction:
event
method should become__call__
: if the method that actually manipulates the data were just__call__
rather thanevent
existing stages would behave like functors, indistinguishably to a direct function call.__init__
method of a stage with a factory function which returns a configured function / immutable functor. Keeping this pickleable will be important for current alphatwirl, although perhaps this restraint might be relaxed in the future too.The text was updated successfully, but these errors were encountered: