code: def __init__(
      self,
      model: RandomForestModel,
      tree_index: int,
      X_train,
      y_train,
      feature_names: List[str] = None,
      target_name: str = None,
      class_names: (List[str], Mapping[int, str]) = None,
  ):
      self.model = model
      if not self.is_fit():
          raise Exception("Model is not fit yet !")
  
      self.tree = self.model.make_inspector().extract_tree(
          tree_idx=tree_index
      )
      (
          self.tree_nodes,
          self.children_left,
          self.children_right,
      ) = self._get_nodes_info()
      self.features = None  # lazy initialization
      self.column_dataspec = self._get_column_dataspec()
      self.node_to_samples = None  # lazy initialization
      self.thresholds = None  # lazy  initialization
  
      super().__init__(
          model,
          X_train,
          y_train,
          feature_names,
          target_name,
          class_names,
      )
  
imports: from collections import defaultdict
  from typing import List, Mapping
  import numpy
  import tensorflow_decision_forests
  from tensorflow_decision_forests.component.py_tree.node import LeafNode
  from tensorflow_decision_forests.keras import RandomForestModel
  from tensorflow_decision_forests.tensorflow.core import Task
  from dtreeviz.models.shadow_decision_tree import ShadowDecTree, VisualisationNotYetSupportedError
label_desc: Use image node_id 1 to create a new ShadowTensorflowTree object from inherited base classes: ShadowDecTree with example: obj = ShadowTensorflowTree(model, tree_index, X_train, y_train, feature_names, target_name, class_names)