def initialize(self):
        self.createEdges()
        # could also set this on G itself ...
        self.unfinished_pred_counts = [ len(filter(lambda i: not self.stages[i].isFinished(),
                                                   self.G.predecessors(n)))
                                        for n in xrange(self.G.order()) ]
        for n in self.computeGraphHeads():
            self.enqueue(n)
Successive patches are applied and reverted just like a single patch.
dataset/ETHPy150Open Mouse-Imaging-Centre/pydpiper/pydpiper/pipeline.py/Pipeline.initialize--crossover with--dataset/ETHPy150Open nlloyd/SubliminalCollaborator/libs/twisted/trial/test/test_tests.py/MonkeyPatchMixin.test_successivePatches