def event_switch(self, solver, event_info):
    if (not all(event_info)):
        solver.sw = [(not solver.sw)]
def event_switch(self, solver, event_info):
    if (not all(event_info)):
        solver.sw = [(not solver.sw)]