def __init__(self, config, root_smiles=None): if root_smiles: self.root = Node.create_root(smiles=root_smiles, tree=self, config=config) else: self.root = None self._config = config self._graph = None
def __init__(self, config: Configuration, root_smiles: str = None) -> None: if root_smiles: self.root: Optional[Node] = Node.create_root(smiles=root_smiles, tree=self, config=config) else: self.root = None self.config = config self._graph: Optional[nx.DiGraph] = None
def wrapper(smiles): return Node.create_root(smiles, tree=None, config=default_config)