class_docstr: Create `pydot` graph object from PyTensor function.
  
  Parameters
  ----------
  compact : bool
      if True, will remove intermediate variables without name.
  
  Attributes
  ----------
  node_colors : dict
      Color table of node types.
  apply_colors : dict
      Color table of apply nodes.
  shapes : dict
      Shape table of node types.
class_docstr_tok: ["Create","`","pydot","`","graph","object","from","PyTensor","function",".","Parameters","--","--","--","--","--","compact",":","bool","if","True",",","will","remove","intermediate","variables","without","name",".","Attributes","--","--","--","--","--","node_colors",":","dict","Color","table","of","node","types",".","apply_colors",":","dict","Color","table","of","apply","nodes",".","shapes",":","dict","Shape","table","of","node","types","."]
docstr: Add new node to node list and return unique id.
  
  Parameters
  ----------
  node : PyTensor graph node
      Apply node, tensor variable, or shared variable in compute graph.
  
  Returns
  -------
  str
      Unique node id.
docstr_tok: ["Add","new","node","to","node","list","and","return","unique","id",".","Parameters","--","--","--","--","--","node",":","PyTensor","graph","node","Apply","node",",","tensor","variable",",","or","shared","variable","in","compute","graph",".","Returns","--","--","--","-","str","Unique","node","id","."]
code: def __add_node(self, node):
      """Add new node to node list and return unique id.
  
      Parameters
      ----------
      node : PyTensor graph node
          Apply node, tensor variable, or shared variable in compute graph.
  
      Returns
      -------
      str
          Unique node id.
      """
      assert node not in self.__nodes
      _id = f"{self.__node_prefix}{len(self.__nodes) + 1}"
      self.__nodes[node] = _id
      return _id
  
imports: import os
  from functools import reduce
  import numpy
  import pytensor
  from pytensor.compile import Function, builders
  from pytensor.graph.basic import Apply, Constant, Variable, graph_inputs
  from pytensor.graph.fg import FunctionGraph
  from pytensor.printing import pydot_imported, pydot_imported_msg
label_desc: Use image node_id 2 for calling the PyDotFormatter obj's underlying member method code with example usage: obj.__add_node(node) and returns: _id