class_docstr: Generate a `GraphRewriter` of type `WalkingGraphRewriter`.
class_docstr_tok: ["Generate","a","`","GraphRewriter","`","of","type","`","WalkingGraphRewriter","`","."]
code: def __init__(
      self,
      db,
      order="in_to_out",
      ignore_newtrees=False,
      failure_callback=None,
  ):
      super().__init__()
      self.db = db
      self.order = order
      self.ignore_newtrees = ignore_newtrees
      self.failure_callback = failure_callback
  
imports: import copy
  import math
  import sys
  from collections.abc import Iterable, Sequence
  from functools import cmp_to_key
  from io import StringIO
  from typing import Optional, Union
  from pytensor.configdefaults import config
  from pytensor.graph.rewriting import basic
  from pytensor.misc.ordered_set import OrderedSet
  from pytensor.utils import DefaultOrderedDict
label_desc: Use image node_id 1 to create a new TopoDB object from inherited base classes: RewriteDatabase with example: obj = TopoDB(db, order, ignore_newtrees, failure_callback)