def __init__(self, requires_grad=True, run_only_once=False): if not isinstance(requires_grad, bool): raise TypeError( f"Expect bool, got : ({type(requires_grad)}){requires_grad}") if not isinstance(run_only_once, bool): raise TypeError( f"Expect bool, got : ({type(run_only_once)}){run_only_once}") self.requires_grad = requires_grad self.run_only_once_ = run_only_once PyPassManager_.__init__(self)
def __init__(self, pipeline_phase=phase.opt, run_only_once=False, multi_graph=True): if not isinstance(pipeline_phase, phase): raise TypeError(f"Expecting phase, got : ({type(pipeline_phase)}){pipeline_phase}") if not isinstance(run_only_once, bool): raise TypeError(f"Expecting bool, got : ({type(run_only_once)}){run_only_once}") if not isinstance(multi_graph, bool): raise TypeError(f"Expecting bool, got : ({type(multi_graph)}){multi_graph}") PyPassManager_.__init__(self) self.phase_ = pipeline_phase self.run_only_once_ = run_only_once self.multi_graph_ = multi_graph
def __init__(self, pipeline_phase=phase.opt, run_only_once=False): if not isinstance(pipeline_phase, phase): raise TypeError( f"Expect phase, got : ({type(pipeline_phase)}){pipeline_phase}" ) if not isinstance(run_only_once, bool): raise TypeError( f"Expect bool, got : ({type(run_only_once)}){run_only_once}") PyPassManager_.__init__(self) self.phase_ = pipeline_phase self.run_only_once_ = run_only_once
def __init__(self, run_only_once=False): if not isinstance(run_only_once, bool): raise TypeError( f"Expect bool, got : ({type(run_only_once)}){run_only_once}") self.run_only_once_ = run_only_once PyPassManager_.__init__(self)