Closed willdumm closed 1 year ago
This PR proposes a convenient interface for defining default arguments for weight counting-related methods of HistoryDag subclasses.
_default_args
dag.get_default_args
get_default_args
dag.convert
HistoryDag.from_history_dag
replaces #62 to avoid rebase
This PR proposes a convenient interface for defining default arguments for weight counting-related methods of HistoryDag subclasses.
_default_args
dictionary, and applied by the method decoratordag.get_default_args
get_default_args
on a method causes positional arguments to be positional-only, and keyword arguments to be keyword-onlyget_default_args
takes a list of arguments to be potentially overridden, as well as a count of (non-self) positional arguments.dag.convert
is added as a wrapper forHistoryDag.from_history_dag
.